Distance measuring device, method for generating pixel position distance data, program, and recording medium

The distance measuring device improves measurement accuracy by generating pixel position distance data to correct for thermal expansion and manufacturing variations, preventing misdetection of calibration charts and ensuring precise distance measurement.

WO2025158723A1PCT designated stage Publication Date: 2025-07-31MITSUBISHI ELECTRIC CORP
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
PCT/JP2024/036909
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-04-11
Filing Date
2024-10-16
Publication Date
2025-07-31

AI Technical Summary

Technical Problem

Existing image reading devices face limitations in distance measurement accuracy due to manufacturing variations in the rod lens array and thermal expansion of the substrate, leading to errors in calculating pixel positions, and are prone to misdetection of calibration charts due to scratches, defects, or dirt.

Method used

A distance measuring device that includes a line image reading unit, storage unit, and processor to generate pixel position distance data by binarizing chart waveform data, determining dark pixel ranges, and calculating representative pixel positions to correct for thermal expansion and manufacturing variations, thereby preventing misdetection of calibration charts.

Benefits of technology

The solution enhances measurement accuracy by correcting for thermal expansion and manufacturing variations, ensuring reliable calibration and precise distance measurement despite environmental factors and chart imperfections.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure JP2024036909_31072025_PF_FP_ABST
    Figure JP2024036909_31072025_PF_FP_ABST
Patent Text Reader

Abstract

A distance measuring device 200 for measuring a target distance between a plurality of points in a main scanning direction on the basis of read waveform data, wherein a processor 210: converts the waveform data into a binarized waveform 75 via binarization on the basis of a predetermined intensity threshold; compares the binarized waveform 75 and arrangement information 74 of dark patterns formed on a distance correction chart 25 and converts the binarized waveform 75 into a dark value pixel range 76, which is a range of pixels consistent with the arrangement information 74 of the dark pattern and located between two dark values each having an adjacent bright value to the outside thereof; calculates a reference physical point distance, which is the distance between a pixel position in the dark value pixel range 76 and a reference pixel position, on the basis of the physical position and physical width of the dark pattern in the distance correction chart 25 included in the arrangement information 74 of the dark pattern; generates pixel position distance data 77 including the pixel position and the reference physical point distance; and outputs the target distance, measured using the pixel position distance data 77, of a distance measurement target.
Need to check novelty before this filing date? Find Prior Art

Description

Distance measurement device, pixel position distance data generation method, program, and recording medium

[0001] The present disclosure relates to a distance measurement device, a method for generating pixel position distance data, a program, and a recording medium.

[0002] Image reading devices, the applications of which have expanded in recent years, are sometimes used to measure distances between arbitrary positions in the main scanning direction of an original document because they form erect, life-size images. However, due to the influence of manufacturing variations in image reading devices, manufacturing variations in rod lens arrays, and thermal expansion of the substrate on which the light receiving elements are fixed, there is a limit to the measurement accuracy when calculating distances simply from the read waveform, i.e., the number of elements (number of pixels) of the light receiving elements involved in waveform reading.

[0003] For this reason, corrections are made to improve the accuracy of distance measurement (for example, see Patent Documents 1 and 2). Patent Document 1 describes a method in which a calibration chart with black lines drawn at known intervals is prepared, the chart is read by an image sensor, and correction is performed.

[0004] Patent Document 2 describes a method for correcting the effects of thermal expansion.

[0005] Japanese Patent Application Laid-Open No. 5-172531 International Publication No. 2020 / 129850

[0006] The technique described in Patent Document 1 has a problem in that calibration errors occur due to erroneous detection of the calibration chart caused by scratches, defects, or stains on the calibration chart.

[0007] The technique described in Patent Document 2 does not describe any correction that takes into consideration expansion and contraction due to thermal expansion of the image reading device itself.

[0008] The present disclosure is intended to solve the above-mentioned problems, and aims to provide a distance measurement device, a method for generating pixel position distance data, a program, and a recording medium that can prevent erroneous detection of a calibration chart due to scratches, defects, or dirt on the calibration chart, perform calibration reliably, and improve the accuracy of distance measurement.

[0009] The distance measurement device according to the present disclosure has a plurality of light receiving elements arranged in the main scanning direction, and includes a line image reading unit that reads an object to be read, converts the light intensity received by each light receiving element into an electrical signal, and generates waveform data that is a line image recorded for each pixel that corresponds to the arrangement position of each light receiving element in the main scanning direction, a memory unit, and a processor. The memory unit stores waveform data, dark pattern arrangement information including physical widths, which are the widths of each dark pattern in a distance correction chart having a predetermined length in a first direction, in which a plurality of dark patterns having a lightness less than a predetermined dark lightness threshold are arranged at predetermined intervals in the first direction and which are parallel to a second direction perpendicular to the first direction, with light patterns having a lightness greater than a predetermined light lightness threshold and greater than the dark lightness threshold being arranged between the dark patterns, and dark pattern arrangement information including physical positions, which are positions in the first direction, or information that can calculate the physical positions, distance measurement point information, which is information about distance measurement points included in a distance measurement object, which is a reading object that includes distance measurement points, which are multiple points that are objects for measuring the distance in the main scanning direction, and pixel position distance data used when measuring the distance between distance measurement points, which is the distance between distance measurement points. The processor includes a waveform data acquisition unit that acquires waveform data generated by the line image reading unit from the line image reading unit and writes the data to a storage unit; a binary image data conversion unit that converts the received light intensity of each pixel of chart waveform data, which is waveform data generated by reading the distance correction chart, which is a reading target arranged so that a first direction is parallel to the main scanning direction, and written to the storage unit by the waveform data acquisition unit, into binary chart waveform data, which is binarized based on a determined intensity threshold into dark values ​​that represent a received light intensity lower than the intensity threshold and light values ​​that represent a received light intensity higher than the intensity threshold; and a dark value pixel range that is a range of pixels sandwiched between two adjacent dark values ​​in the binary chart waveform data, where the number of pixels included in the dark value pixel range is consistent with the physical width of the corresponding dark pattern included in the dark pattern arrangement information, taking into account the pixel size of the light receiving element, and the number of pixels between adjacent dark value pixel ranges is also taken into account the pixel size.a dark value pixel range determination unit that determines a dark value pixel range that matches a dark pattern physical interval that is determined based on the difference between the physical position of an adjacent dark value pattern, which is a dark pattern corresponding to an adjacent dark value pixel range, and the physical position of the own dark value pattern; a dark value pixel range determination unit that determines a representative pixel position expressed as a pixel position that is the position of a pixel in waveform data using the same determination method for each dark value pixel range; a representative physical point that corresponds to the representative pixel position in the dark pattern corresponding to each dark value pixel range; a reference pixel position that is a reference pixel position; a reference physical point distance that is a distance between the representative physical point corresponding to each representative pixel position and the reference physical point based on the physical position and physical width included in the dark pattern array information; and a pixel position dependent distance calculated from the pixel position that is the value of the representative pixel position, calculated from the pixel position, based on the reference physical point distance. a pixel position distance data generation unit that generates pixel position distance data including a corrected reference physical point distance obtained by subtracting the reference physical point distance from the pixel position data or a stored reference physical point distance that is the reference physical point distance, and writes the pixel position distance data into the storage unit; a reference physical point distance calculation unit that calculates the reference physical point distance at an input pixel position by referring to the pixel position distance data; and a distance measurement unit that determines distance measurement pixel positions that are pixel positions corresponding to each distance measurement point based on distance measurement point information for distance measurement waveform data that is generated by the line image reading unit reading an object of distance measurement that is arranged so that the line image reading unit can read a plurality of distance measurement points, and that is waveform data that is written into the storage unit by the waveform data acquisition unit, calculates the reference physical point distance for each distance measurement pixel position by the reference physical point distance calculation unit, and measures the absolute value of the difference between the reference physical point distances of the calculated distance measurement pixel positions as the distance between the distance measurement points.

[0010] The pixel position distance data generating method according to the present disclosure is a method for generating pixel position distance data used when measuring the distance in the main scanning direction between multiple predetermined points on a reading object, using a line image reading unit that has a plurality of light receiving elements arranged in the main scanning direction, reads the reading object, converts the received light intensity, which is the intensity of light received by each light receiving element, into an electrical signal, and generates waveform data, which is a line image recorded for each pixel that corresponds to the arrangement position of each light receiving element in the main scanning direction, and a memory unit that stores the waveform data. The pixel position distance data generating method includes the steps of: writing, into a storage unit, dark pattern arrangement information including information for calculating the physical width and physical position in the first direction of each dark pattern in a distance correction chart having a predetermined length in the first direction, the dark patterns having a predetermined width in the first direction and parallel to a second direction perpendicular to the first direction, the dark patterns being arranged at predetermined intervals in the first direction and having light patterns having a lightness greater than a predetermined lightness threshold and greater than the dark lightness threshold between the dark patterns; a chart arrangement step of arranging the distance correction chart so that the first direction is parallel to the main scanning direction; and a step of writing, into the storage unit, chart waveform data generated by reading the arranged distance correction chart with a line image reading unit. a step of converting the received light intensity of each pixel of the waveform data into binarized chart waveform data, binarized into dark values ​​representing that the received light intensity is lower than the intensity threshold value and light values ​​representing that the received light intensity is higher than the intensity threshold value, based on a determined intensity threshold value; and a step of determining a dark value pixel range in the binarized chart waveform data, the dark value pixel range being a range of pixels sandwiched between two dark values ​​each having a light value adjacent to its outer edge, the dark value pixel range having a number of pixels included in the dark value pixel range that matches the physical width of the corresponding self-dense pattern included in the dense pattern arrangement information, taking into account the pixel size of the light receiving element, and the number of pixels between adjacent dark value pixel ranges that matches the dense pattern physical interval that is determined based on the difference between the physical position of the self-dense pattern and the physical position of the adjacent dense pattern that is the corresponding dense pattern, taking into account the pixel size.The method includes the steps of: determining a representative pixel position expressed as a pixel position that is the position of a pixel in waveform data for each dark value pixel range using the same determination method; determining a representative physical point that corresponds to the representative pixel position in a dark pattern that corresponds to each dark value pixel range; setting one of the representative pixel positions as a reference pixel position; setting the representative physical point that corresponds to the reference pixel position as the reference physical point; calculating a reference physical point distance that is the distance between the representative physical point that corresponds to each representative pixel position and the reference physical point based on the physical position and physical width included in the dark pattern arrangement information; and generating pixel position distance data for each representative pixel position that includes the pixel position that is the value of the representative pixel position and a corrected reference physical point distance obtained by subtracting the pixel position-dependent distance calculated from the pixel position from the reference physical point distance, or a stored reference physical point distance that is the reference physical point distance; and writing the pixel position distance data to a storage unit.

[0011] According to the present disclosure, erroneous detection of the calibration chart due to scratches, defects, or dirt on the calibration chart can be prevented, calibration can be performed reliably, and the accuracy of distance measurement can be improved.

[0012] FIG. 1 is a perspective view of an image reading device according to the first embodiment; FIG. 2 is a view showing a state in which an original is being read by the image reading device according to the first embodiment; FIG. 3 is a view showing an output waveform when a black-and-white chart is read by the image reading device according to the first embodiment; FIG. 4 is an enlarged view of an output waveform when a black-and-white chart is read by the image reading device according to the first embodiment; FIG. 5 is a side view of the image reading device according to the first embodiment with the side panel removed; FIG. 6 is a top view of the image reading device according to the first embodiment as seen from the reading surface; FIG. 7 is a view showing a rod lens array according to the first embodiment; FIG. 8 is a view showing an image projection by the rod lens array according to the first embodiment; a block diagram showing the configuration of a distance measurement device according to the first embodiment; a flowchart of pixel position distance data generation processing according to the first embodiment; a flowchart of noise removal processing by pattern matching according to the first embodiment; a flowchart of a part of the noise removal processing; a diagram showing an example of waveform processing of the noise removal processing; a diagram showing an example of a soiled distance correction chart according to the first embodiment; a flowchart of processing to check physical length and line spacing according to the first embodiment; a diagram showing an example of waveform processing of processing to check physical length and line spacing; a flowchart of processing to check chart position validity according to the first embodiment; a flowchart of a part of the processing to check chart position validity; a diagram showing the relationship between the effective reading range and the effective length measurement correction range according to the first embodiment; a diagram showing an example of waveform processing of processing to check chart position validity (first measurement, first side);END side) Flowchart of combining process of first and second measurements according to embodiment 1 Figure explaining combining process of first and second measurements Figure explaining another combining process of first and second measurements Figure showing change in body temperature of image reading device according to embodiment 1 Flowchart of data processing for determining temperature correction coefficient according to embodiment 1 Figure showing positional deviation amount in pixel units according to embodiment 1 Figure showing an example of measurement of change in positional deviation amount per elapsed time according to embodiment 1 Figure showing an example of measurement of change in positional deviation amount with elapsed time according to embodiment 1 Figure showing change in positional deviation amount with respect to temperature Figure showing change in slope of positional deviation amount with respect to temperature depending on pixel position Temperature using temperature correction coefficient Flowchart of correction procedure Block diagram showing the configuration of a distance measurement device according to embodiment 2 Flowchart of pixel position distance data generation process according to embodiments 2 and 3 Block diagram showing the configuration of a distance measurement device according to a first modified example of embodiment 2 Block diagram showing the configuration of a distance measurement device according to a second modified example of embodiment 2 Diagram showing a joint of a rod lens array according to embodiment 3 Diagram showing an attachment part of a rod lens array according to embodiment 3 Diagram showing image formation through a joint of a rod lens 16 according to embodiment 3 Diagram showing length measurement correction values ​​at a joint of a rod lens 16 according to embodiment 3 Block diagram showing the configuration of a distance measurement device according to embodiment 3,

[0013] Hereinafter, embodiments of the present disclosure will be described with reference to the drawings. In the following drawings, the same or corresponding parts are designated by the same reference characters, and description thereof will not be repeated.

[0014] Embodiment 1. FIG. 1 is a perspective view of an image reading device 100 according to embodiment 1. The image reading device 100 according to the present disclosure is a contact image sensor (CIS). As shown in FIG. 1, the x direction is the main scanning direction, the y direction is the sub-scanning direction, and the z direction is the reading depth direction. The side plate 2 is a sealing member for ensuring dust protection inside the image reading device 100. It is generally made of a metal or resin plate. The first transparent body 3 can be made of, for example, resin or glass, and extends in the x direction.

[0015] 2 is a schematic diagram showing a state in which an image of an original M is being captured by the image reading device 100 according to the first embodiment. For example, the original M is a medium to be read (an irradiated object) having image information of a banknote, a security, or other general document. Since the image reading device 100 has a row of light receiving elements 15 in the main scanning direction, capturing an image of the original requires either transporting the original in the sub-scanning direction or moving the image reading device 100 in the sub-scanning direction.

[0016] 3 shows an output waveform 5 of the image reading device 100 when the document M is a black and white chart (black and white chart) as shown in chart 4. The output of the white parts of chart 4 is high and the output of the black parts is low.

[0017] FIG. 4 shows a partially enlarged view of the output waveform 5 of the image reading device 100. The output waveforms of two sample image reading devices 100 are shown by solid and dotted lines. Compared to the deviation between the two waveforms at edge 1 in the upper left of FIG. 4, the deviation between the two waveforms at edge 12 in the lower right of FIG. 4 is greater. In other words, even when the same chart 4 is imaged, the position at which the edge is observed may differ depending on the image reading device 100. For example, if you want to measure the distance between two points using the image reading device 100, you can do so by multiplying the number of pixels between the points by the size of one pixel (42.33 μm for 600 dpi). However, the number of pixels between the points varies depending on the individual image reading device 100, which results in measurement errors.

[0018] Patent Document 1 describes a solution to a similar problem with two-dimensional image sensors. Patent Document 1 proposes a method of preparing a calibration chart with black lines arranged at known intervals, as described below, reading the chart with an image sensor, and performing correction. However, there is no description of a way to avoid calibration errors that occur due to false detection caused by scratches, defects, or dirt on the calibration chart.

[0019] 5 is a side view of the image reading device 100 with the side panel 2 removed. The first transparent body 3 and light source 8 are fixed by a second frame 7. Inside the second frame 7 is a first frame 9. A second transparent body 10, a rod lens array 11, a light receiving element 15, etc. are attached to the first frame 9. The light receiving element 15 is fixed to a substrate 13 with an adhesive. A substrate 14 is fixed to the substrate support plate 12 together with the substrate 13, aligned in the sub-scanning direction with the substrate 13.

[0020] Fig. 6 is a top view of the image reading device 100 as seen from the reading surface. The rod lens array 11 is arranged in the main scanning direction. Fig. 7 is a schematic diagram of the rod lens array 11. Rod lenses 16 are sandwiched between fixed side plates 17, and multiple rod lenses 16 are aligned in the main scanning direction and fixed with adhesive. Fig. 8 is a schematic diagram showing the projection of an image when a document is read with the rod lens array 11.

[0021] Assume that an original 18 with length L is placed at an object distance lo from the rod lens array 11. The rod lens array 11 forms an erect, life-size image 19 at a distance li. When the object distance lo and the image plane distance li are equal and the two are separated by a conjugate length Tc, the position of the light receiving element 15 becomes the focal position, and the rod lens array 11 theoretically forms an image at the same magnification as the original size on the light receiving element side. In other words, when lo = li, the relationship between the original size and the image size is L = L'. However, due to variations in the manufacturing process of the rod lens 11 or the manufacturing process of the image reading device 100, even if the relationship lo = li is satisfied, L = L' may not be strictly satisfied. In other words, the image may be enlarged or reduced relative to the original.

[0022] Figure 9 shows a top view of the structure, with the light-receiving element 15, substrate 13, and substrate 14 fixed to the substrate support plate 12, removed from the first frame 9. The light-receiving elements 15 (pixels) are arranged continuously in the main scanning direction over the effective reading length. The effective reading length is the length in the main scanning direction of the reading range in which the light-receiving elements are arranged. However, after power-on, the image reading device 100 generates heat and begins to thermally expand. Because the substrate 13 is constructed as a single unit in the main scanning direction without being divided, thermal expansion occurs. Because the light-receiving element 15 is fixed to the substrate 13 via adhesive, the position of the light-receiving element 15 also changes in accordance with the thermal expansion of the substrate 13. A commonly used material for the substrate 13 is glass-reinforced epoxy resin, such as FR-4. Glass-reinforced epoxy resin expands as its temperature increases. Therefore, when the image reading device 100 generates heat, the number of pixels decreases, making the document appear smaller, even if the same size document is read.

[0023] The problem of variations in the number of pixels between points due to manufacturing variations in the image reading device 100 or the rod lens array 11 can be solved by generating pixel position distance data and applying it to the measurement results. Therefore, a method for generating pixel position distance data will be described below. The pixel position distance data is data that allows calculation of the distance between each pixel position and a reference pixel position. The pixel position is determined based on the array position in the main scanning direction of the light receiving element that outputs the data displayed by that pixel. The pixel position can take on a non-integer value. The pixel position distance data is equivalent to the data shown in Figure 4 of Patent Document 1. The distance on the screen, which is the horizontal axis of Figure 4 of Patent Document 1, corresponds to the difference in pixel position.

[0024] First, the image reading device 100 must be fixed in an appropriate environment. Figure 10 shows a fixing jig used when creating pixel position distance data. The image reading device 100 is fixed to a table 20, the flatness of which is ensured, by fixtures 21 and 22 via a rail 24 that is movable in the main scanning direction. However, the fixture 21 on the first side fixes the image reading device 100 with, for example, a screw. This fixes the image reading device 100 on the first side during measurement. When creating pixel position distance data, a distance correction chart 25 is placed on the table 20.

[0025] When the effective reading length of the image reading device 100 is long, the length of the distance correction chart 25 may be shorter than the effective reading length due to chart manufacturing reasons. In this case, pixel position distance data can be acquired by dividing the image reading device 100 into the first pixel side and the end pixel side. First, the distance correction chart 25 is placed on the first pixel side as shown in FIG. 11A so that the black line 26 numbered 1 is located on the first pixel side, and waveform data is acquired. Next, the distance correction chart 25 is placed on the end pixel side as shown in FIG. 11B so that the black line 26 numbered 1 is located on the first pixel side, and waveform data is acquired. Note that the distance correction chart 25 must be placed on the table 20 parallel to the image reading device 100, and rotation in the θ direction must be minimized. (A structure for suppressing rotation in the θ direction may be provided on the table 20.)

[0026] θ is the angle of rotation around a rotation axis perpendicular to the table 20. Rotation in the θ direction is shown in Figure 12. The waveform data is data in which the received light intensity output by each light receiving element 15 is arranged in the order in which the light receiving elements 15 are arranged. In the x direction, which is the main scanning direction, the x coordinate of the first pixel is smaller than the x coordinate on the end pixel side. The waveform data is data in which the x coordinate representing the position at which the light receiving elements 15 are arranged corresponds to the received light intensity output by the light receiving element 15 at that position. The pixel position is the position of the pixel in the waveform data.

[0027] 12 is a top view of the distance correction chart 25. On the distance correction chart 25, black lines 26 are drawn at regular intervals in a first direction, which is the extension direction of the distance correction chart 25. The thickness and spacing of the black lines 26 on the chart are both arbitrary, but a thickness of about 200 μm and spacing of about 1 mm are preferable. Furthermore, in order to reduce the effects of thermal expansion due to changes in the measurement environment (room temperature), the distance correction chart 25 is preferably made of stainless steel or glass as its base material.

[0028] The black lines of the distance correction chart may be dark blue or dark brown, and the background color of the distance correction chart may be light gray or yellow instead of white. Any chart with regularly-spaced dark lines on a light background can be used as a distance correction chart. More specifically, any chart with a light and dark pattern in which multiple dark patterns (lines) with a brightness lower than a predetermined dark brightness threshold are drawn parallel to each other at regular intervals, and between the dark patterns (lines) there are light patterns (background) with a brightness higher than the dark brightness threshold and higher than a predetermined light brightness threshold can be used as a distance correction chart. The longitudinal direction of the distance correction chart is the first direction, and the dark patterns (lines) are drawn parallel to a second direction perpendicular to the first direction. In the distance correction chart 25, which is a black and white pattern, the black lines 26 are dark patterns, and the white background between the black lines 26 is light patterns.

[0029] FIG. 13 is a block diagram showing the configuration of a distance measurement device 200 according to this embodiment. The distance measurement device 200 includes an image reading device 100 having light-receiving elements 15 (pixels) arranged in the main scanning direction as described above, a processor 210, and a storage unit 220. The image reading device 100 reads a distance correction chart 25, on which black and white patterns are formed at regular intervals in a first direction, by aligning the main scanning direction with the first direction, and generates waveform data of the black and white patterns. The distance measurement device 200 processes the waveform data of the black and white patterns read by the image reading device 100 to generate pixel position distance data 77. Furthermore, the distance measurement device 200 calculates and outputs object distances between multiple points in the main scanning direction using the pixel position distance data 77 based on the waveform data acquired by reading a distance measurement object with the image reading device 100. The distance measurement device 200 includes the image reading device 100, the processor 210, and the storage unit 220 housed in a single housing. The image reading device 100 may be arranged separately from the housing of the processor 210 and the storage unit 220 .

[0030] The processor 210 is equipped with, for example, a CPU (Central Processing Unit), and by executing programs stored in the memory unit 220, functions as a waveform data acquisition unit 51, a binarized waveform conversion unit 52, an edge information conversion unit 53, a pixel position distance data generation unit 54, a reference physical point distance calculation unit 55, a temperature correction unit 56, and a distance measurement unit 57.

[0031] The storage unit 220 includes a RAM (Random Access Memory), an EEPROM (Electrically Erasable and Programmable Read Only Memory), a flash memory, or other non-volatile memory. The storage unit 220 stores data necessary for data processing by the processor 210, data generated by the data processing, and various programs executed by the processor 210.

[0032] The image reading device 100 is a line image reading unit that has a plurality of light receiving elements 15 arranged in the main scanning direction, reads an object to be read, converts the received light intensity, which is the intensity of light received by each light receiving element 15, into an electrical signal, and generates waveform data, which is a line image recorded for each pixel associated with the arrangement position in the main scanning direction of each light receiving element 15. The waveform data acquiring unit 51 receives the waveform data read by the image reading device 100 from the image reading device 100, and writes it to the memory unit 220 as waveform data 71.

[0033] The waveform data 71 includes chart waveform data 72 and distance measurement waveform data 73. The chart waveform data 72 is waveform data 71 generated by reading the distance correction chart 25. The distance measurement waveform data 73 is waveform data 71 generated by reading an object to be measured for distance.

[0034] The following describes the data stored in the storage unit 220. The storage unit 220 has waveform data 71 (chart waveform data 72, distance measurement waveform data 73), dark pattern arrangement information 74, binarized waveform 75, edge information 76, pixel position distance data 77, pixel size 78, distance measurement point information 79, distance between distance measurement points 80, calibration temperature 81, temperature correction coefficient 82, operation mode 83, and edge detection data 84.

[0035] The dark pattern arrangement information 74 is information that indicates how the black lines 26 (dark patterns) are arranged on the distance correction chart 25. The dark pattern arrangement information 74 stores the physical width, which is the width of the black lines 26, and the physical position, which is the position of each black line 26 in the first direction on the distance correction chart 25. The position of a point on the distance correction chart 25 relative to some reference point is called a physical position. Each black line 26 is assigned a number, and with the first direction being the x-axis, the black line 26 with the smallest x-coordinate is numbered 1. The center point in the first direction of the black line 26 numbered 1 is used as the reference point, and the distance from the center point in the first direction of each black line 26 to the reference point is stored as the physical position. If the physical widths of the black lines 26 differ, the dark pattern arrangement information 74 stores the physical width for each black line 26. A point on the distance correction chart 25 that exists as an object is called a physical point. The length on the distance correction chart 25 is called the physical width or physical interval.

[0036] The distance correction chart 25 has black lines 26 (dark patterns) of the same physical width arranged at the same physical intervals. The same physical intervals mean that the difference in physical position between a dark pattern and an adjacent dark pattern is the same for all dark patterns. Some dark patterns may have different physical widths. There may be some dark patterns where the difference in physical position between a dark pattern and an adjacent dark pattern varies. The physical width of the dark pattern needs to be determined for each dark pattern. The physical position of the dark pattern needs to be determined for each dark pattern.

[0037] When black lines 26 (dark patterns) of the same physical width are arranged at the same physical intervals, as in the distance correction chart 25, the dark pattern arrangement information 74 may be stored as the physical width, physical interval, the position in the main scanning direction of the black line 26 numbered 1, and the number of black lines 26. With such dark pattern arrangement information 74, the physical position of each black line 26 can be calculated from the number of the black line 26, the position in the main scanning direction of the black line 26 numbered 1, and the physical interval. Such dark pattern arrangement information 74 stores information from which the physical position of each black line 26 (dark pattern) can be calculated. The physical width stored in the dark pattern arrangement information 74 may be a single value or a range.

[0038] The binarized waveform 75 is data that stores binarized chart waveform data in which the chart waveform data 72 is binarized into dark values ​​that represent received light intensity lower than a predetermined intensity threshold value and bright values ​​that represent received light intensity higher than the predetermined intensity threshold value, based on the received light intensity of each pixel determined based on the predetermined intensity threshold value. When the received light intensity is the same as the intensity threshold value, the binarization may be performed into either a dark value or a bright value.

[0039] The edge information 76 is a pixel range sandwiched between two dark values ​​each having a bright value adjacent to the outside in the binarized chart waveform data stored as the binarized waveform 75, and is data that stores a dark value pixel range that matches the dense pattern arrangement information 74. The dark value pixel range is a range sandwiched between a falling edge and a rising edge. The dark value pixel range will be described in detail later.

[0040] The pixel position distance data 77 is data that includes, for a pixel position determined from each dark value pixel range, that pixel position and a reference physical point distance, which is the distance between that pixel position and a reference pixel position. The reference physical point distance is calculated from the physical width, which is the width of each black line 26 on the distance correction chart 25, and the physical position, which is the position in the first direction. The reference physical point distance is a distance equivalent to the value obtained by multiplying the number of pixels by the pixel size and adding the length measurement correction value to the distance. How the pixel position for each dark value pixel range is determined and how the reference physical point distance is calculated will be explained later.

[0041] The pixel size 78 is data that stores the size of one pixel (pixel size) determined by the resolution (dpi) of the light receiving element 15. In this specification, the case of 600 dpi, that is, a pixel size of 42.3 μm will be described.

[0042] The distance measurement point information 79 is data that stores distance measurement point information, which is information on distance measurement points included in a distance measurement target that is a reading target that includes distance measurement points, which are multiple points that are targets for measuring distance in the main scanning direction. The distance between distance measurement points 80 is data that stores the distance between distance measurement points, which is the distance measured by the distance measurement unit 57 between the distance measurement points determined by the distance measurement point information 79. The distance between distance measurement points is also called the target distance.

[0043] The calibration temperature 81 and the temperature correction coefficient 82 are data used by the temperature correction unit 56 when performing temperature correction on the pixel position distance data. The calibration temperature 81 is data that stores the temperature of the image reading device 100 when the chart waveform data 72 was read. The temperature correction coefficient 82 is data that stores the temperature correction coefficient by which the temperature difference is multiplied. The operation mode 83 is data that indicates whether the mode is a mode for creating pixel position distance data (calibration mode) or a mode for measuring the distance between distance measurement points (measurement mode).

[0044] The edge detection data 84 is data used by the edge information conversion unit 53 so that when the edge information conversion unit 53 detects falling edges and rising edges, it can detect a dark value pixel range that matches the dark pattern array information 74. The edge detection data 84 will be described in the description of the processing of the edge information conversion unit 53. The edge detection data 84 can also be considered data that stores dark pattern array information.

[0045] Even when the dark pattern arrangement information 74 is stored as part of the program rather than as data separate from the program, the program is stored in the storage unit 220, and therefore the dark pattern arrangement information 74 is stored in the storage unit 220. Even when the pixel size 78, distance measurement point information 79, calibration temperature 81, temperature correction coefficient 82, and edge detection data 84 are stored as part of the program, the program is stored in the storage unit 220, and therefore these data are also stored in the storage unit 220.

[0046] The binary waveform converter 52 acquires waveform data obtained by the image reading device 100 reading the distance correction chart 25 and converts the waveform data into a binary waveform 75 binarized based on a predetermined intensity threshold. The binary waveform converter 52 is a binary image data converter that converts the received light intensity of each pixel of chart waveform data 72, which is waveform data generated by the image reading device 100 reading the distance correction chart 25, which is positioned so that the first direction is parallel to the main scanning direction, and written to the storage unit 220 by the waveform data acquisition unit 51, into binary chart waveform data stored as a binary waveform 75 binarized based on a predetermined intensity threshold into dark values ​​representing received light intensity lower than the intensity threshold and bright values ​​representing received light intensity higher than the intensity threshold. In this specification, a case where dark values ​​are "0" and bright values ​​are "1" will be described. The binary waveform converter 52 may also perform binarization so that dark values ​​are "1" and bright values ​​are "0."

[0047] The edge information conversion unit 53 compares the binarized waveform 75 with the thickness and spacing of the black lines 26 represented by the dark pattern array information 74, and converts the binarized waveform 75 into edge information 76 indicating the pixel positions of falling edges and rising edges with noise removed. A falling edge is a pixel position where a value changes from a light value (1) to a dark value (0). A rising edge is a pixel position where a value changes from a dark value (0) to a light value (1). Therefore, the falling edges and rising edges stored in the edge information 76 are data that store dark value pixel ranges, which are ranges of pixels whose light values ​​are sandwiched between two adjacent dark values ​​on the outside. The dark value pixel ranges may include pixels that are light values. As will be explained in more detail later, the process of detecting falling edges and rising edges is a process of determining a dark value pixel range such that the number of pixels included in the dark value pixel range matches the physical width of the corresponding self-dense pattern, which is included in the dense pattern array information, taking into account the pixel size of the light receiving element, and the number of pixels between adjacent dark value pixel ranges matches the dense pattern physical spacing, which is determined based on the difference between the physical position of the adjacent dense pattern, which is the dense pattern corresponding to the adjacent dark value pixel range, and the physical position of the self-dense pattern, taking into account the pixel size. The edge information conversion unit 53 is a dark value pixel range determination unit that determines the dark value pixel range.

[0048] The pixel position distance data generation unit 54 determines a representative pixel position, which is expressed as a pixel position that is the position of a pixel in the waveform data, for each dark value pixel range represented by the edge information 76 using the same determination method. It also determines a representative physical point corresponding to the representative pixel position in the dark pattern corresponding to each dark value pixel range, and designates one of the representative pixel positions as the reference pixel position, and the representative physical point corresponding to the reference pixel position as the reference physical point. The pixel position distance data generation unit 54 calculates the reference physical point distance, which is the distance between the representative physical point corresponding to each representative pixel position and the reference physical point, based on the physical position and physical width included in the dark pattern array information. For each representative pixel position, the pixel position distance data generation unit 54 generates pixel position distance data including the pixel position, which is the value of the representative pixel position, and the reference physical point distance. The pixel position distance data generated by the pixel position distance data generation unit 54 is stored in the storage unit 220 as pixel position distance data 77.

[0049] In the processing of the pixel position distance data generation unit 54, a method for determining the representative pixel position of a dark value pixel range is, for example, a method in which the average of the pixel positions at both ends of the dark value pixel range is used as the representative pixel position. When the representative pixel position is determined by average, the representative physical point on the distance correction chart 25 corresponding to the representative pixel position is the central physical point in the first direction on the line (reading line) of the black line 26 corresponding to the dark value pixel range that is read by the image reading device 100. Alternatively, the pixel position on the first side of the dark value pixel range may be used as the representative pixel position. When the pixel position on the first side of the dark value pixel range is used as the representative pixel position, the representative physical point on the distance correction chart 25 corresponding to the representative pixel position is the end point on the first side of the reading line of the black line 26.

[0050] The representative pixel position in the dark value pixel range on the 1st side among the representative pixel positions is set as the reference pixel position. The representative physical point corresponding to the reference pixel position is set as the reference physical point. The reference physical point is the center point in the first direction on the reading line of the black line 26 numbered 1. The reference physical point distance at the reference physical point is 0. Since all black lines 26 have the same thickness, the reference physical point distance of the representative physical point on the black line 26 numbered as a natural number n is (n-1)*Δd, where Δd is the spacing between the black lines 26.

[0051] The reference physical point distance calculation unit 55 calculates the reference physical point distance at the input pixel position by referring to the pixel position distance data 77. The reference physical point distance calculation unit 55 calculates the reference physical point distance for the input pixel position based on a pixel position distance graph that connects two points corresponding to pixel position distance data that are adjacent pixel positions with a straight line on a two-dimensional plane of pixel positions and reference physical point distances. The pixel position distance graph may also be one that connects two points corresponding to adjacent pixel position distance data with a curved line.

[0052] Based on distance measurement waveform data 73 acquired by reading the distance measurement target with image reading device 100, distance measurement unit 57 calculates and outputs object distances between multiple points in the main scanning direction using pixel position distance data 77. More specifically, distance measurement pixel positions, which are pixel positions corresponding to each distance measurement point, are determined based on distance measurement point information, and reference physical point distances for each distance measurement pixel position are calculated by reference physical point distance calculation unit 55. The absolute value of the difference between the reference physical point distances for the calculated distance measurement pixel positions is measured as the distance between distance measurement points, which is the distance between the distance measurement points. The distance between distance measurement points is the distance measured and output by distance measurement device 200.

[0053] The temperature correction unit 56 performs processing so that the distance between the distance measurement points can be measured after being corrected based on the difference between the temperature of the image reading device 100 and the temperature at the time of calibration and the temperature correction coefficient.

[0054] 14 is a flowchart of a pixel position distance data generation process executed by the processor 210 to generate pixel position distance data 77 based on waveform data obtained by reading the distance correction chart 25. The process will be described below in order.

[0055] First, the binary waveform converter 52 performs a binary process on the waveform data acquired from the image reading device 100 (step 1, first step). The waveform is expressed as 0 or 1, with an arbitrarily determined intensity threshold as the boundary. An example of the process of binarizing waveform data will be described with reference to FIG. 16 . In FIG. 16 , the intensity threshold is set to 128, and the acquired waveform data (solid line) is converted into a binary waveform (dotted line). The value of each pixel in the binary waveform is a bright value (1) for pixels that have read a white pattern, and a dark value (0) for pixels that have read a black pattern. More specifically, the falling edge where the value of the binary waveform 75 changes from 1 to 0 in the direction of increasing x-coordinate is estimated as the position where the distance correction chart 25 changes from a white pattern to a black pattern, and the rising edge where the value of the binary waveform 75 changes from 0 to 1 is estimated as the position where the distance correction chart changes from a black pattern to a white pattern.

[0056] Next, the edge information conversion unit 53 performs noise removal by pattern matching (step 2, step 2). Specifically, the edge information conversion unit 53 compares the binarized waveform with dense pattern arrangement information 74 representing the black and white patterns formed on the distance correction chart 25, and converts the binarized waveform 75 into edge information 76 including falling and rising edges with noise removed. Flowcharts of the noise removal process are shown in FIGS. 15A and 15B. Because the width of the black and white patterns on the distance correction chart 25 to be read is predetermined, the arrival positions of rising edges (binarized waveform 0 → 1) and falling edges (binarized waveform 1 → 0) are predictable. The purpose of this process is to remove falling or rising edges that deviate significantly from the predicted arrival positions, thereby improving the reliability of the pixel position distance data 77. Examples of events that could impair the reliability of the pixel position distance data 77 include the events listed in the possible failure modes in FIG. 17 occurring on the distance correction chart 25. To avoid these problems, it is effective to (i) set upper and lower limits for the width of the black line 26, and (ii) restrict the lower limit of the width of the plain white portion 27. The upper and lower limits of the width of the black line 26, the lower limit of the width of the plain white portion 27, the measurement start pixel position, and the measurement end pixel position are stored in the memory unit 220 as edge detection data 84. The edge detection data 84 is set so that the falling edge and the rising edge can be detected even if the light receiving element 15 is misaligned or its position changes due to thermal expansion. A falling edge and a rising edge adjacent to the falling edge on the side with a larger x-coordinate are considered to be a corresponding pair of falling and rising edges.

[0057] First, the image reading device 100 binarizes waveform data obtained by scanning in the main scanning direction, and the edge information conversion unit 53 sequentially reads the binarized waveform data (step S101). When the number of pixels reaches a predetermined measurement start pixel or more (step S102: Yes), detection of the falling edge, which is the starting point of the black pattern of the black line 26 in the main scanning direction, is enabled (step S103, step 21). If a falling edge is detected in the area above the measurement start pixel (area A in Figure 16 ) (step S104: Yes), the received light data from the pixel where the falling edge was detected is invalidated, and falling edge detection is disabled (step S105, step 22). The pixel position distance data generation unit 54 stores the edge position and the falling edge in the memory unit 220 (step S106). Thereafter, rising edge detection is not performed until the minimum number of pixels of the width of the black line 26 is reached. This is to prevent false detection in the event of a white scratch or chipping in the black line 26 (area B in Figure 16 ). While a falling edge is not detected (step S104: No), the waveform is repeatedly read (step S102).

[0058] After detecting a falling edge, if the pixel width exceeds the width at which rising edge detection is prohibited (lower limit of black line width) (step S108: Yes), the pixel position distance data generator 54 validates the received light data, enables rising edge detection, and begins monitoring the width of the black line (step S109, step 23), because the pixel width falls within the range predicted for the end of the black pattern (FIG. 16, area C). In other words, rising edge detection is enabled when the predicted end pixel of the black pattern in the main scanning direction is reached. By enabling rising edge detection at the predicted end pixel, erroneous detection of black foreign matter adjacent to the black line can be prevented and edge droop can be detected.

[0059] Furthermore, the pixel position distance data generator 54 reads the waveform (step S110). If a rising edge is detected as expected in the region below the upper limit of the black line width (step S111: Yes) (step S112: Yes), the received light data from the pixel where the rising edge was detected (region D in FIG. 16) onward is invalidated (step 24). That is, the rising edge detection is invalidated, and monitoring of the black line width is reset (step S114). Even if the rising edge does not arrive as expected, if the upper limit of the black line width is exceeded (step S111: No), and the read data exceeds the range of the predicted end pixel of the black pattern in the main scanning direction, the rising edge detection is invalidated, and the process is forced to proceed to step S114 (step 24). This is to prevent false detection when black stains or scratches are attached to the plain white portion 27 (region D in FIG. 16). Until a rising edge arrives (step S112: No), if the value of the binarized waveform is "0" (step S115: No), the process returns to step S110, and if the value of the binarized waveform is "1" (step S115: Yes), the process proceeds to step S114.

[0060] The pixel position distance data generator 54 then reads the waveform data (step S116). If the pixel is not the final pixel to be measured (step S117: No), or if the pixel is below the lower limit of the solid white width (step S118: Yes), the process returns to step S116. When the pixel exceeds the lower limit of the solid white width (step S118: No), enters the range where the falling edge of the black line 26 is predicted to arrive, and reaches the measurement start pixel for the next black pattern in the main scanning direction, the process returns to step S101 and re-enables falling edge detection (Figure 16, area A'). When the waveform readout reaches the final pixel to be measured (step S117: Yes), if it is the first measurement (step S119: Yes), the process proceeds to a second waveform acquisition and binarization process (step S120). If it is the second measurement (step S119: No), the process ends, the detected edge information 76 is written to the memory unit 220, and the process proceeds to the next step.

[0061] If the black lines 26 on the distance correction chart 25 are 211.5 μm wide and the center-to-center spacing of the black lines 26 is 1 mm, the width of the black lines 26 will be approximately 5 pixels, and the width of the plain white areas 27 will be approximately 18.5 pixels. If the lower limit of the width of the black lines 26 is 3.5 pixels, the upper limit is 6.5 pixels, and the lower limit of the plain white areas 27 is 15.5 pixels, the width of the black lines 26 will be ±1.5 pixels, and the width of the plain white areas 27 will be -3 pixels. Since false detection will not be effective, this may result in a distance correction error. This range can be changed arbitrarily, but narrowing the range may increase the risk of edge undetection. To compensate for this disadvantage, further data processing is performed in the physical length confirmation and line spacing confirmation processes described below.

[0062] The edge information conversion unit 53 uses a matching determination condition that determines whether a dark pixel range, which is a pair of a falling edge and a rising edge, matches the corresponding black line 26 (dark pattern). Among the matching determination conditions, finding a falling edge and a rising edge such that the width of the black line 26 has a lower limit of 3.5 pixels and an upper limit of 6.5 pixels means satisfying a width pixel number condition, which determines whether the number of pixels in the dark pixel range falls within a width pixel number range defined by a lower limit of 3.5 pixels and an upper limit of 6.5 pixels. The width pixel number range includes the value (approximately 5 pixels) obtained by dividing the physical width of the black line 26, 211.5 μm, by the pixel size, 42.3 μm.

[0063] Next, the physical length confirmation and line spacing confirmation process will be described (steps 3 and 3 in FIG. 14). In this process, the pixel position distance data generation unit 54 compares the edge information 76 with the physical length of the black and white patterns on the distance correction chart 25 to derive the number of pixels (number of light receiving elements) corresponding to the physical spacing between adjacent black patterns in the main scanning direction. The physical spacing between black patterns is the spacing between the black lines 26 on the distance correction chart 25. A processing flowchart for this process is shown in FIG. 18. The waveform data at this time has been converted into edge information 76 by noise removal using pattern matching. The pixel position distance data generation unit 54 reads the edge information 76 (step S201) and performs various processes.

[0064] First, the pixel position distance data generator 54 deletes falling edge information for which no rising edge exists on the side with a larger x coordinate (step S202, step 31). That is, if a rising edge adjacent to a falling edge has not been detected, the falling edge is deleted. This is because if a rising edge is not detected by the pattern matching process, the rising edge information is missing, and so the process here ultimately leaves only the black line 26 that has been correctly detected.

[0065] Next, the pixel position distance data generator 54 calculates the average pixel position of the adjacent rising edge and the falling edge whose x coordinate is smaller than that of the adjacent rising edge, and records this as the position of the black line 26 (black pattern) (step S203, step 32). More specifically, the pixel that detected the falling edge is defined as the falling detection pixel, and the pixel that detected the adjacent rising edge corresponding to the falling edge is defined as the rising detection pixel, and the position of the average value of the positions of the falling detection pixel and the rising detection pixel is defined as the pixel position of the black line 26. The pixel position of the black line 26 is the average of the pixel positions of the pixels at both ends of the dark value pixel range, which is the range of pixels that read the black line 26.

[0066] 14 (flowchart in FIG. 15A), the pixel position distance data generator 54 derives the pixel positions of the plurality of black lines 26 (step 33) by performing the process of step S203 on the plurality of falling edges and rising edges repeatedly detected in step 2. Then, based on the pixel positions of the black lines 26 calculated in step S203, the pixel position distance data generator 54 calculates the number of pixels corresponding to the distance between adjacent black lines 26 (step S204). The product of the number of pixels that is the difference in pixel positions between adjacent black lines 26 and the size of one pixel is called the spacing between the pixel positions of the plurality of black lines 26.

[0067] Next, the estimated interval estimated from the intervals between the pixel positions of the plurality of black lines 26 is compared with the physical intervals between the black lines 26 on the distance correction chart 25. If, as a result of the comparison, it is determined that the absolute value of the difference between the estimated intervals between the pixel positions of the plurality of black lines 26 and the physical intervals between the black lines 26 on the distance correction chart 25 is equal to or less than a predetermined threshold, the number of pixels between the pixel positions of adjacent black lines 26 is set to the number of pixels corresponding to the physical intervals between the black lines 26 on the distance correction chart 25. If it is determined that the absolute value of the difference between the estimated intervals between the pixel positions of the plurality of black lines 26, which is an integer multiple of two or more of the physical intervals between the black lines 26 on the distance correction chart 25, is equal to or less than a predetermined threshold, the number of pixels between the pixel position obtained by interpolating the black line 26 and the pixel position of the adjacent black line 26 is set to the number of pixels corresponding to the physical intervals between the black lines 26 on the distance correction chart 25 (step 34). That is, the condition for the number of pixels between the black lines 26 is that the absolute value of the difference between the pixel positions of the black lines 26 on the distance correction chart 25 and an integer multiple of one or more of the physical spacing between the black lines 26 is equal to or less than a predetermined threshold value, and the number of detailed pixels corresponding to the spacing between adjacent black lines is determined depending on whether or not this condition is met (step S205).

[0068] This will be explained in detail using the example of a black line 26 shown in FIG. 19. The positions (circled 1), (circled 2), and (circled 3) are spaced 23.5 pixels apart, and if the spacing between the black lines 26 were 1 mm, it would be understood that no black lines 26 would have been missing along the way. On the other hand, there is a gap of 47 pixels between positions (circled 3) and (circled 5), which corresponds to a spacing of 2 mm, and it can be inferred that one black line 26 between them has been missing due to some abnormality. In FIG. 19, position (circled 1) indicates "1 in a circle" in the figure. Similarly, position (circled 2) indicates "2 in a circle" in the figure. The same applies to positions (circled 3) and beyond. In this specification and figures, "numbers in circles" are used in the same way.

[0069] Since the physical spacing of the black lines 26 is known, if the spacing is 1 mm, there should be black lines 26 approximately every 23.5 pixels, and the line spacing is determined based on this. For example, after position (circled 3) in Figure 19, a black line 26 is expected to be present at position (circled 4). If a black line 26 is present within a range of 23.5 ± 1 pixels from position (circled 3), it is recognized that the black lines 26 existed at an interval of 1 mm. However, in the case of Figure 19, there is no positional information for the black line 26 at position (circled 4), so it is ignored.

[0070] Next, a black line 26 is expected to exist at position (circle 5). If a black line exists within a range of 47±1 pixels from position (circle 3), it will be recognized that the black line 26 exists at an interval of 2 mm. In the case of Figure 19, since the black line 26 exists at position (circle 5), the line interval between positions (circle 3) and (circle 5) will be recognized as 2 mm. Similarly, if a black line exists within a range of 70.5±1 pixels from position (circle 3), it will be recognized that the black line 26 exists at an interval of 3 mm.

[0071] In this way, even if the position of the black line 26 is not detected in the previous step of noise removal by pattern matching (step 2 in FIG. 14), data processing continues if the next black line 26 is recognized in the correct position. This means that even if strict conditions are set in noise removal by pattern matching to prevent erroneous detection due to chips or scratches on the black line 26 or scratches or stains on the plain white area 27, and black lines 26 are ignored excessively, the generation process of pixel position distance data can continue using the remaining correctly detected black lines 26. Of course, the expected range of the black line 26 can be set arbitrarily (set to ±1 pixel in FIG. 19).

[0072] Furthermore, by performing this process, if a black scratch 28 on a plain white area 27 shown in Figure 17 (an enlarged view of the enlarged portion of Figure 12) is erroneously detected as a black line 26, the next black line 26 will not fit within the specified ranges (23.5±1 pixels, 47±1 pixels, 70.5±1 pixels) and will be ignored. Therefore, this process also serves to remove noise that could not be completely removed by pattern matching.

[0073] 18 illustrates an example in which two consecutive black lines 26 are missing (the expected position range of the black lines 26 is 70.5±1 pixels, corresponding to an interval of 3 mm between the black lines 26). If three or more consecutive black lines 26 are missing, the interval pixel number condition is not met (step S205: No), and an error message is displayed (step S207), the process is forcibly terminated, and the user is prompted to remeasure.

[0074] It is possible to arbitrarily set the number of consecutive missing lines before prompting remeasurement. For example, if a maximum measurement error of 0.5 mm is expected at an effective reading length of 900 mm, the measurement error expected to occur at 3 mm is 1.7 μm. This is sufficiently small, since the size of one pixel on a 600 dpi light receiving element 15 is 42.3 μm (measurement errors smaller than the size of one pixel cannot be detected). It is also sufficiently smaller than the maximum expected measurement error.

[0075] In this way, the maximum number of black lines 26 that can be missing can be determined by taking into account the maximum expected length measurement error or the size of the light-receiving element 15. If it is determined that the determined interval pixel number condition is met, including the number of missing black lines 26 (step S205: Yes), data is recorded in the form of pixel position - adjacent black line interval (physical length) (step S206). Note that the starting point (0 mm) position is the position where the first black line 26 was detected in each measurement. The pixel position at which the adjacent black line interval (physical length) is recorded is the representative pixel position of each dark value pixel range. The representative pixel position of a dark value pixel range is the average of the pixel positions of the pixels at both ends of the dark value pixel range.

[0076] The physical length confirmation and line spacing confirmation processes use a spacing pixel number condition that the absolute value of the difference between the spacing between the pixel positions of the multiple black lines 26 and the physical spacing between the black lines 26 on the distance correction chart 25 is equal to or less than a predetermined threshold. The absolute value of the difference between the physical spacing between the multiple black lines 26 and the integer multiple of the physical spacing is the absolute value of the difference between the physical positions of the multiple black lines 26, since the physical spacing between the multiple black lines 26 is the same everywhere. The spacing between the pixel positions of the multiple black lines 26 is calculated by multiplying the number of pixels between the representative pixel positions of the dark value pixel ranges (pairs of falling edges and rising edges) corresponding to each of the multiple black lines 26 by the pixel size. The spacing pixel number condition means that the number of pixels between two adjacent dark value pixel ranges is consistent, taking into account the pixel size, as determined by the difference between the physical position of the dark pattern corresponding to one dark value pixel range and the physical position of the adjacent dark pattern corresponding to the other dark value pixel range. When the spacing between multiple dark value pixel ranges is calculated without including the number of pixels contained in the dark value pixel range, the physical spacing of the dark patterns is determined based on the difference in physical position between the original dark pattern and the adjacent dark pattern and the physical width of the original dark pattern and the adjacent dark pattern.

[0077] The physical length and line spacing confirmation process checks whether, for each combination of two adjacent dark value pixel ranges, the number of pixels between the two adjacent dark value pixel ranges is included in the interval pixel number range determined to include the value obtained by dividing the physical interval between two dark patterns corresponding to each of the two dark value pixel ranges by the pixel size. By including the physical length and line spacing confirmation process, it is possible to confirm that the match determination condition is met when both the width pixel number condition and the interval pixel number condition are met.

[0078] Next, the pixel position distance data generation unit 54 performs a process to confirm the validity of the chart position in order to guarantee the valid range of the measurement correction (steps 4 and 4 in FIG. 14). The process flowcharts are shown in FIGS. 20A and 20B. FIG. 21 shows the valid document reading range and valid range of the measurement correction value of the image reading device 100.

[0079] The effective document reading range refers to the range determined from the first pixel position to the last pixel position of the light-receiving element 15. On the other hand, the effective measurement correction value range is narrower than the effective document reading range because pixel position distance data is generated based on waveform data from the distance correction chart 25 captured by the image reading device 100. However, when used for distance measurement in a customer's process, the effective measurement correction value range must be clearly defined. Measurement correction values ​​can only be generated within the range where the black line 26 on the distance correction chart 25 exists. Therefore, to clearly define the effective measurement correction value range, it is necessary to specify the expected positions of the black line 26 on the first pixel side and the expected positions of the black line 26 on the end side and to confirm that the black line 26 actually exists within those ranges. Furthermore, it is necessary to confirm that the black line 26 is not an erroneous detection line due to dirt or scratches on the white solid area, and to confirm that the distance correction chart 25 is in the desired position in order to perform the first- and second-read data combination process described below.

[0080] Specifically, the pixel position distance data generation unit 54 determines that the black pattern of the distance correction chart 25 appears within a range from the first pixel position to the final pixel position in the main scanning direction, within a range between the predetermined expected position of the black pattern on the first pixel side and the expected position of the black pattern on the final pixel side.

[0081] As an example, the first measurement (first-side measurement) will be described. FIG. 22 shows the detection status of the black line 26 up to the 188th pixel on the first side in the first measurement. The position of the black line 26 closest to the first side (circled 1 in FIG. 22) is the 16th pixel. The area surrounded by the black dotted line is the expected presence position range on the first side (0 to 23.5 pixels). It is determined whether the first observation line is within the expected presence position range (step S301). In the example shown in FIG. 22, the black line 26 actually exists within the expected presence position range. Note that if the expected presence position range is set to within 23.5 pixels from the first pixel / end pixel, the guaranteed effective range of the length measurement correction value is 1 mm inside the effective document reading range (approximately 2 mm shorter than the effective document reading range).

[0082] Next, the pixel position distance data generation unit 54 checks whether the distance correction chart 25 was placed in the correct position when the image was captured, in order to confirm that the black line 26 in Figure 22 (circled 1) is not a falsely detected line and that data has been correctly acquired up to the range expected in advance for the data connection process with the second measurement data.

[0083] FIG. 22 shows an example of the detection status of the black lines 26 up to the 188th pixel on the first side in the first measurement. After confirming that the position of the black line 26 closest to the first side (first observation line) is within the expected presence range (step S301: Yes), the pixel position distance data generation unit 54 then checks whether the second line (circled 2 in FIG. 22) and the third line (circled 3 in FIG. 22) are consecutive within a range of 23.5±1 pixels (corresponding to 1 mm) (steps S302 and S303). This is because if three consecutive black lines 26 are detected, it can be confirmed that the distance correction chart 25 is correctly positioned, at least on the first side. The number of consecutive lines required to determine whether the chart is correctly positioned can be set arbitrarily.

[0084] Similarly, for the END side, the pixel position distance data generation unit 54 confirms that the black line 26 closest to the END side (the final observation line, (circled 1) in Figure 23) is present within the expected position range (in the case of Figure 23, the range within 23.5 pixels from the first final measurement position of 12,000 pixels, the range surrounded by the black dotted line frame) (step S304).

[0085] Thereafter, the pixel position distance data generator 54 checks whether the previous observation line (circled 2 in FIG. 23) and the observation line two lines before (circled 3 in FIG. 23) are continuous within a range of 23.5±1 pixels (corresponding to 1 mm) (steps S305 and S306). In the example of FIG. 23, both conditions are met, and there is no problem with the position on the END side.

[0086] Since it was confirmed that the distance correction chart 25 was placed in the correct position on both the 1st side and the END side, and since it was confirmed that the position of the first black line 26 on the 1st side and the position of the last black line 26 on the END side were within the expected position range, the image reading device 100 determines that there was no problem with the position of the distance correction chart 25 at the time of the first measurement (steps S301 to S306: Yes).

[0087] On the other hand, if the position of the first black line 26 on the 1st side and the position of the last black line 26 on the END side are not within the expected position range (steps S301 and S304: No), the pixel position distance data generation unit 54 displays an error message (step S307) and terminates the process. Also, if the distances between the first and second observation lines, the second and third observation lines, the last observation line and the observation line immediately preceding it, or the observation line immediately preceding it and the observation line immediately preceding it are not within the range of 23.5±1 pixels (corresponding to 1 mm) (steps S302, S303, S305, and S306: No), the pixel position distance data generation unit 54 displays an error message (step S307) and terminates the process.

[0088] If the data being processed in steps S301 to S306 is the first data (step S308: No), the process returns to step S301, and the data being processed in steps S301 to S306 is executed for the second data to determine whether there is a problem with the position of the distance correction chart 25. If the data being processed in steps S301 to S306 is the second data (step S308: Yes), the process ends.

[0089] Completion of this process determines (guarantees) the valid range of the length measurement correction values ​​and determines that there will be no problems in the process of combining the first measurement data and the second measurement data, which will be described later.

[0090] The chart position validity confirmation process is a process that verifies whether an edge pixel range condition, which verifies whether one dark value pixel range is included in each of a predetermined number of edge pixel ranges, which are pixel ranges determined at both ends of multiple light receiving elements arranged in the main scanning direction. Observation lines correspond to dark value pixel ranges. The expected presence position ranges for each observation line are the respective edge pixel ranges. Three (a predetermined number) expected presence position ranges are determined at each end of the light receiving elements, and the edge pixel range condition is satisfied when each expected presence range contains one observation line (dark value pixel range). The edge pixel range condition is not satisfied when there is an expected presence range that does not contain an observation line (dark value pixel range).

[0091] Next, the pixel position distance data generation unit 54 combines data for the number of pixels corresponding to the physical spacing between the black patterns on each distance correction chart 25 when multiple distance correction charts 25 are arranged in the main scanning direction. For example, the first measurement data and second measurement data are combined (steps 5 and 5 in FIG. 14 ). A processing flowchart is shown in FIG. 24 . Note that this process can be skipped if the effective reading length of the image reading device 100 is short and the distance correction chart 25 is sufficiently longer than the effective reading length, since splitting the measurement is unnecessary. The length in the main scanning direction of the correctable range, which is the range sandwiched between the dark patterns arranged at both ends of the distance correction chart 25 in the main scanning direction, is called the correctable length. If the correctable length of the distance correction chart 25 is longer than the effective reading length, step 5 is unnecessary.

[0092] When the correctable length of the distance correction chart 25 is shorter than the effective reading length, the chart placement position, which is the position in the main scanning direction at which the distance correction chart 25 is placed, is determined so that there are portions where the correctable ranges at adjacent chart placement positions overlap, and the sum of the correctable ranges at each chart placement position includes the reading range, or the length in the main scanning direction of the non-correctable range, which is the range included in the reading range but not included in the sum of the correctable ranges, is equal to or less than a predetermined upper limit value of the non-correctable range length. When the distance correction chart 25 is read at each of the determined chart placement positions and multiple sets of pixel position distance data are generated, the role of the fifth step is to generate pixel position distance data that includes the pixel positions obtained at the chart placement positions and the reference physical point distances from a common reference physical point. Note that when the distance correction chart 25 is read for the second or subsequent times to generate pixel position distance data, if pixel position distance data having the reference physical point distance from the reference physical point in the pixel position distance data generated the first time is generated, the fifth step is not necessary.

[0093] This will be explained using the data processing example shown in Figure 25. First, the first measurement result is read (step S401). In the example of Figure 25, the end position of the first measurement data acquisition is set to the 12,000th pixel. Next, the pixel position of the final black line 30 of the first measurement is identified (step S402), and then the first measurement result is copied to the final result file (step S403).

[0094] Next, the cumulative physical length is calculated from the adjacent black line spacing calculated and recorded in the physical length confirmation and line spacing confirmation process (step 3 in FIG. 14). The cumulative physical length is then recorded along with the pixel position of the final black line 30 from the first measurement result copied to the final result file (step S404). The cumulative physical length is calculated by adding up the values ​​of the adjacent black line spacing up to the pixel position for which calculation is desired. The cumulative physical length is the reference physical point distance, with the representative physical point corresponding to the representative pixel position of the dark value pixel range corresponding to the black line 26 detected closest to the first side being used as the reference physical point. Because the pixel position at which the adjacent black line spacing (physical length) is recorded is the representative pixel position of the dark value pixel range, the pixel position-cumulative physical length data at each pixel position is pixel position distance data including the pixel position and the reference physical point distance.

[0095] The chart placement position where the distance correction chart 25 is placed the first time is called the first chart placement position. The chart placement position where the distance correction chart 25 is placed the second time is called the second chart placement position. The first chart placement position and the second chart placement position are two adjacent chart placement positions. A set of pixel position-cumulative physical length data (pixel position distance data) generated by placing the distance correction chart 25 the first time is called the first pixel position distance data set. A set of pixel position-cumulative physical length data (pixel position distance data) generated by placing the distance correction chart 25 the second time is called the second pixel position distance data set. The range of pixel positions included in any of the pixel position distance data belonging to the first pixel position distance data set is called the first pixel position definition range 32 (shown in FIG. 26 ).

[0096] Next, the pixel position distance data generator 54 reads the second measurement data (step S405) and determines whether the black line in the second measurement data exceeds the pixel position of the final black line 30 in the first measurement (step S406). If there is a first valid start black line 29 that exceeds the pixel position of the final black line 30 in the first measurement (step S406: Yes), an offset value is calculated (step S407). Note that even if the final black line 30 in the first measurement and the second measurement black line match in step S406, the process may proceed to step S407. As long as the black line in the second measurement data does not exceed the pixel position of the final black line 30 in the first measurement (step S406: No), the reading of the second measurement data continues (step S405). Strictly speaking, the pixel position of the final black line 30 in the first measurement is the average pixel position of the pixel positions of the pixels at both ends of the dark value pixel range corresponding to the final black line 30 in the first measurement. The same applies to the pixel position of the valid start black line 29.

[0097] The offset value calculated in step S407 is the value obtained by subtracting the pixel position of the final black line 30 in the first measurement from the pixel position of the effective start black line 29 in the second measurement data that first coincides with or exceeds the final black line 30 in the first measurement. If the offset value exceeds a preset value (step S408: Yes), an error message and a prompt to remeasure are displayed (step S409), and the process ends. This is because there is no pixel position distance data 77 between the final black line 30 in the first measurement and the pixel position of the effective start black line 29 in the second measurement data that exceeds the final black line 30 in the first measurement, and it is desirable to set an upper limit for this offset value in consideration of the accuracy of distance correction.

[0098] The offset tolerance can be set arbitrarily. How the offset tolerance should be set can be considered in the same way as the concept of setting tolerances in the physical length confirmation and line spacing confirmation processes. If the offset value is within the preset tolerance (step S408: No), the actual measurement data merging process is started. The second measurement data is recorded additionally following the first measurement data, as described below.

[0099] If the offset value is 0 (the final black line 30 in the first measurement and the effective start black line 29 in the second measurement completely coincide) (Step S410: Yes), the final black line 30 in the first measurement and the effective start black line 29 in the second measurement overlap, and the second measurement data sequentially records pixel position and cumulative physical length data starting from the black line next to the overlapping effective start black line 29 (Step S412). If the offset value is not 0 (Step S410: No), distance A is calculated by multiplying the offset value from the pixel position of the first effective start black line 29 in the second measurement by 1 pixel size, adding distance A to the cumulative physical length of the final black line 30 in the first measurement, and recording this as the cumulative physical length of the effective start black line 29 in the second measurement (Step S411). Thereafter, pixel position distance data generator 54 adds the spacing between adjacent black lines from the second effective black line onward to the final black line in the second measurement, and records this as the cumulative physical length for image reading device 100, along with the black line pixel positions (Step S412). By the above processing, when the distance correction chart 25 is arranged at multiple positions in the main scanning direction, the pixel position distance data generation unit 54 can combine data on the number of pixels corresponding to the cumulative physical length, which is the physical spacing between the black patterns of the distance correction chart at each position.

[0100] In the processing flowchart shown in Figure 24, when each pixel position distance data belonging to the first pixel position distance data set and the second pixel position distance data set has a reference physical point distance relative to a common reference physical point, the pixel position of the final black line 30 of the first measurement, the pixel position of the effective start black line 29 that first coincides with the final black line 30 of the first measurement or exceeds the final black line 30, and distance A are used.

[0101] The pixel position of the final black line 30 of the first measurement is the first boundary pixel position, which is the pixel position at the end of the first pixel position definition range 32 on the side where each pixel position distance data belonging to the second pixel position distance data set exists. The pixel position of the effective start black line 29 that first coincides with the final black line 30 of the first measurement or exceeds the final black line 30 is the first adjacent second pixel position, which is a pixel position included in the pixel position distance data belonging to the second pixel position distance data set and has an adjacent minimum pixel position difference that is the minimum value of the difference between the pixel position and the first boundary pixel position, and is the same pixel position as the first boundary pixel position or a pixel position that is not included in the first pixel position definition range 32. The offset value is the adjacent minimum pixel position difference that is the minimum value of the difference between the pixel position and the first boundary pixel position. Distance A is the adjacent pixel position difference distance obtained by multiplying the adjacent minimum pixel position difference by the pixel size.

[0102] When placing the distance correction chart 25 at three or more chart placement positions and generating pixel position distance data including the pixel positions obtained at each chart placement position and the reference physical point distances relative to a common reference physical point, it is sufficient to repeatedly process the first pixel position distance data set and the second pixel position distance data set at two adjacent chart placement positions.

[0103] Another combining process of the first and second measurements will be described with reference to FIG. 26. In this other combining process, an offset value is not used. In FIG. 26, the black line of the second measurement that exists just before (on the 1st side of) the pixel position of the final black line 30 of the first measurement is called the first range second black line 33. In FIG. 26, the pixel positions of the four first range second black lines 33 are written. Starting from the one closest to the final black line 30 of the first measurement, 1 , 33 2 , 33 3 , 33 4The pixel positions of the first range second black line 33 are included in the first pixel position definition range 32, so the pixel position-cumulative physical length data (pixel position distance data) of the first measurement at the pixel positions of the first range second black line 33 can be used to calculate the reference physical point distance (referred to as the first reference physical point distance) relative to the reference physical point of the first measurement at the pixel positions of the first range second black line 33. The first reference physical point distance at the pixel positions of the first range second black line 33 can be used to convert the cumulative physical length (reference physical point distance) into the first reference physical point distance in the pixel position-cumulative physical length data (pixel position distance data) of the other second measurement. By converting to the first reference physical point distance, each pixel position distance data belonging to the first pixel position distance data set and the second pixel position distance data set has a reference physical point distance relative to a common reference physical point.

[0104] The pixel position of the first range second black line 33 is a first range second pixel position which has a pixel position included in the first pixel position definition range 32 and is a pixel position included in pixel position distance data belonging to the second pixel position distance data set. The reference physical point distance to the reference physical point of the first measurement at the pixel position of the first range second black line 33 is a first range second pixel position reference physical point distance which is the reference physical point distance to the reference physical point in the pixel position distance data belonging to the first pixel position distance data set.

[0105] The first reference physical point distance may be calculated for one first-range second black line 33, or for multiple first-range second black lines 33. When calculating the first reference physical point distance for multiple first-range second black lines 33, the first reference physical point distance at a certain pixel position of the second measurement (selected second pixel position) is calculated as the average or median based on the first reference physical point distances at each of the multiple first-range second black lines 33. Then, based on the first reference physical point distance at the selected second pixel position, the cumulative physical length (reference physical point distance) in the pixel position-cumulative physical length data (pixel position distance data) of the other second measurements is converted into the first reference physical point distance.

[0106] Up to this point, we have explained the data processing method for generating pixel position distance data 77 by capturing an image of distance correction chart 25 with image reading device 100 to address the issue of variations in the number of pixels between points due to manufacturing variations in image reading device 100 or manufacturing variations in rod lens array 11. These processes must be performed individually for each image reading device 100 for which pixel position distance data 77 is to be generated.

[0107] Next, a correction method for the problem that the position of the light receiving element 15 changes due to thermal expansion when the image reading device 100 is powered on, resulting in a measurement error during length measurement, will be described.

[0108] Patent Document 2 describes a method for correcting the effects of thermal expansion, although the correction chart has a different format. However, this method is related to correcting the thermal expansion of the calibration plate itself, and does not take into account the expansion and contraction due to thermal expansion of the image reading device itself.

[0109] FIG. 27 is a graph showing the relationship between temperature and time from when the image reading device 100 (contact image sensor: CIS) is turned on. When the power is turned on, the temperature of the image reading device 100 begins to rise, and after 120 minutes has passed since the power was turned on, it reaches thermal equilibrium and the temperature change becomes small. The image reading device 100 is incorporated into a device that inspects objects for scratches, chips, etc., and therefore operates continuously for long periods of time. For this reason, it is effective to understand the effects of thermal expansion approximately 120 minutes after the power is turned on, when it reaches thermal equilibrium.

[0110] However, if it is necessary to wait 120 minutes to obtain the pixel position distance data 77, a delay will occur in the process of obtaining the pixel position distance data 77 during the assembly process of the image reading device 100, which will result in an increase in the manufacturing cost of the image reading device 100.

[0111] Therefore, during the assembly process of the image reading device 100, pixel position distance data 77 at a certain temperature is acquired, and pixel position distance data 77 at a temperature that could not be measured during the assembly process can be estimated using parameters determined experimentally in advance. This makes it possible to correct the temperature dependency of the pixel position distance data 77 without impairing the productivity of the image reading device 100.

[0112] Therefore, here, a method for experimentally extracting the temperature dependency of pixel position distance data 77 in advance will be described. First, a description will be given of the measurement environment required for experimentally extracting the temperature dependency of pixel position distance data 77. The measurement environment used is the environment shown in FIG. 10.

[0113] The image reading device 100 is fixed to a table 20, the flatness of which is ensured, by fixtures 21 and 22 via a rail 24 that is movable in the main scanning direction. However, the fixture 21 on the 1st side fixes the image reading device 100 with, for example, a screw. This allows the image reading device 100 to be fixed on the 1st side during measurement. The fixture 22 on the END side is configured so that the image reading device 100 can move only in the main scanning direction. When acquiring waveform data, a distance correction chart 25 is placed on the table 20. If the effective reading length of the image reading device 100 is long, the length of the distance correction chart 25 may be shorter than the effective reading length due to chart manufacturing reasons. In this case, pixel position distance data can be acquired by dividing the 1st pixel side and the END pixel side of the image reading device 100.

[0114] An infrared sensor 23 is placed on the table 20 to monitor the temperature of the image reading device 100. While the distance correction chart 25 is being used to measure the temperature characteristics of the pixel position distance data 77, the infrared sensor 23 measures the time-temperature relationship from when the image reading device 100 is turned on. In FIG. 10, the infrared sensors 23 are placed in three locations, but the number of locations can be changed as desired. The means for monitoring the temperature is not limited to an infrared sensor, and a contact thermometer, a non-contact thermometer, a thermocouple, etc. may also be used.

[0115] The temperature correction process will be described with reference to Fig. 28. Fig. 28 is a flowchart of data processing for determining a temperature correction coefficient. First, the image reading device 100 for acquiring temperature characteristics is placed on the table 20, and the distance measurement device 200 acquires waveform data of the CIS temperature / distance correction chart using the distance correction chart 25 (step 11).

[0116] Next, the pixel position distance data generator 54 performs the same processes as steps 1 to 5 in Fig. 14 on the distance correction chart 25 acquired in step 11, and converts the waveform data of the distance correction chart 25 into a relationship between pixel position and cumulative physical length (step S12). That is, the processes of steps 13 to 18 in Fig. 28 correspond to the temperature correction process of step 6 performed after steps 1 to 5 in Fig. 14.

[0117] Here, image acquisition and conversion into the relationship between pixel position and cumulative physical length in steps 1 to 5 of Figure 14 must be performed immediately after power-on, when the image reading device 100 reaches thermal equilibrium, and at several points in between. Note that in Figure 30 (described below), images are acquired at 0 minutes (immediately after power-on), 5 minutes, 10 minutes, 30 minutes, and 120 minutes (thermal equilibrium state), but any time other than 0 minutes (immediately after power-on) and the thermal equilibrium state can be set. However, shortening the time interval allows for more data points when converting to time-position deviation data in step 14 (described below), which is advantageous when calculating the temperature correction coefficient in steps 16, 17, and 18.

[0118] The pixel position distance data generator 54 records the relationship between pixel position and cumulative physical length obtained in step S12 together with the time elapsed since power-on. If pixel position distance data acquisition is divided into two or more times, the data is combined at this stage (step 5 in FIG. 14).

[0119] Next, the pixel position distance data generating unit 54 approximates the amount of deviation for each pixel from the discrete waveform data (every 1 mm) at each elapsed time, and generates continuous waveform data (step 13). A more detailed explanation of this process will be given. First, the amount of positional deviation at the pixel position is calculated using the calculation method shown in the following equation (1). Amount of positional deviation = cumulative physical length at the pixel position - pixel size of one pixel x (pixel position - 26 pixel position of the first black line) (1)

[0120] If the amount of positional misalignment is a positive value, the captured image is smaller than the original. If the amount of positional misalignment is a negative value, the captured image is larger than the original. The calculation result is data in the form of pixel position - amount of positional misalignment at that pixel position. The pixel position for which the amount of positional misalignment is set is the position of the black line 26 on the distance correction chart 25, and the data is for every 23.5 pixels (every 1 mm).

[0121] In step 13, when considering temperature-related correction, it becomes difficult to extract the amount of misalignment at the same pixel position at each temperature when performing step 14 (described later in FIG. 28 ) using only the position information of the black line 26. Therefore, the pixel position distance data generator 54 calculates the amount of misalignment for pixel positions other than the pixel position where the black line 26 is recorded, and continuously records the amount of misalignment for all pixels of the image reading device 100. An example of the calculation results of the amount of misalignment on a pixel-by-pixel basis is shown in FIG. 29 . There is data for the black line 26 at pixels 11013.5 and 11037.5. There is no data for the black line 26 at pixel positions between these two. For pixel positions between these two, the processor 210 uses linear approximation to calculate the amount of misalignment from the recorded amount of misalignment at the position of the black line 26. Then, data on the approximate value of the amount of misalignment for each pixel is recorded. In this way, the relationship between pixel position and amount of misalignment at each elapsed time of the image reading device 100 is recorded. FIG. 30 shows an example of measurement of the change in the amount of positional deviation over time.

[0122] Next, the pixel position distance data generator 54 extracts the positional misalignment amount for each pixel position at a certain interval (for example, 1000 pixel intervals) from the pixel position-positional misalignment amount relationship calculated in step 13, and generates data on the relationship between elapsed time and positional misalignment amount (step 14). That is, the pixel position-positional misalignment amount data is converted into positional misalignment amount data for the same pixel position with respect to elapsed time. Figure 31 shows an example of measuring the change in positional misalignment amount with respect to elapsed time.

[0123] In the example of Figure 31, the misalignment amounts at 100 pixels, 1,000 pixels, 2,000 pixels, 10,000 pixels, 20,000 pixels, 21,000 pixels, and 21,500 pixels are extracted from the data in Figure 30. The more pixel positions extracted, the higher the accuracy of the approximation process described below. Therefore, it is desirable to extract data at as many pixel positions as possible, but the extraction frequency can be set as desired. Since the horizontal axis is converted to time, the pixel position distance data generator 54 uses the relationship between the body temperature and the elapsed time since the power supply of the image reading device 100 was turned on, acquired by the infrared sensor 23, to convert the data obtained in step 14 into the relationship between the body temperature of the image reading device 100 and the misalignment amount (step 15). That is, the pixel position distance data generator 54 calculates the change in the misalignment amount with respect to temperature, as shown in Figure 32, based on the relationship between elapsed time and temperature shown in Figure 27 and the relationship between elapsed time and misalignment amount shown in Figure 31.

[0124] 32, the pixel position distance data generating unit 54 then performs a linear approximation calculation for each pixel position using the least squares method (step 16). The linear expansion amount is defined by the following equation (2): Linear expansion amount (change in positional deviation) ΔL=α×L×ΔT (2) where α is the linear expansion coefficient, L is the pixel position from the first pixel, and ΔT is the temperature difference.

[0125] The linear expansion coefficient α is a value determined by the material. However, since the image reading device 100 is a combination of various components, it is not easy to estimate. If L is considered a constant, the relationship between temperature and misalignment amount can be linearly approximated from the linear expansion equation. For the graph in FIG. 32, if a linear approximation is performed using, for example, the least squares method, the misalignment amount is expressed by the following equation (3). In equation (3), b is a term that is not temperature-dependent, i.e., it can be ignored when determining the amount of change in the misalignment amount. (Misalignment amount) = a × (Temperature) + b (3)

[0126] Since FIG. 32 is a graph created for each pixel position L corresponding to the distance from the starting point (pixel position) of the pixel position distance data 77, focusing on each line representing the misalignment amount at each pixel position L, the pixel position L can be considered a constant. Each line for each pixel position L in FIG. 32 indicates that the misalignment amount changes with temperature. The slope a of linear approximation within the temperature range shown in the graph in FIG. 32 increases with distance from the starting point (pixel position) of the pixel position distance data 77. This means that for a given temperature T, the misalignment amount increases with increasing pixel position L. While the linear expansion coefficient α generally depends on temperature, as shown in FIG. 27 , the ΔT of the image reading device 100 is at most about 20°C, and the operating environment is room temperature (about 24°C), the linear expansion coefficient α can be considered constant. Therefore, the slope a of equation (3) when linearly approximating the change in misalignment amount with temperature corresponds to α×L in equation (2) for linear expansion ΔL, but only the pixel position L can be treated as a variable. The pixel position distance data generator 54 extracts the gradient a (a1, a2, a3, ... a7) of the linear approximation result at each pixel position L to create the relationship between pixel position and gradient a as shown in Fig. 33 (step S17). Fig. 33 is a diagram showing how the gradient a of the positional deviation amount with respect to temperature changes depending on the pixel position.

[0127] Since the gradient a has a linear response to the pixel position L, the pixel position distance data generating unit 54 again performs linear approximation on the graph using the least squares method (step S18). When the linear approximation is performed, the following equation (4) is derived: (gradient) a = c × (pixel position from the 1st pixel) + d (4)

[0128] Therefore, the amount of positional misalignment is expressed by the following equation (5). In equation (5), b is a term that does not depend on temperature, that is, it can be ignored when calculating the amount of change in positional misalignment. (Amount of positional misalignment) = (c × (pixel position from the 1st pixel) + d) × (temperature) + b (5)

[0129] Furthermore, the necessary information is the positional misalignment amount change ΔL when the body temperature of the image reading device 100 becomes Tcis, which is calculated based on the positional misalignment amount L' measured on a mass production line when the body temperature of the image reading device 100 is at a certain temperature T'. ΔL is calculated using the following formula (6). Temperature T' is the calibration temperature, which is the temperature of the image reading device 100 when the chart waveform data 72 is read to generate the pixel position distance data 77. Positional misalignment amount change ΔL=(c×(pixel position from the 1st pixel)+d)×(Tcis-T') (6)

[0130] In the above formula (6), c and d are items related to the linear expansion coefficient that should be determined in advance through experiments from the graph shown in Figure 33, and are temperature correction coefficients. Since these are constant unless the materials or combination of parts changes, it is sufficient to determine the values ​​experimentally in advance for each model. Coefficients c and d are stored in the storage unit 220 as temperature correction coefficients 82.

[0131] Furthermore, by monitoring Tcis and determining the pixel position for which the amount of misalignment is to be calculated, the change in the amount of misalignment can be calculated using equation (6). Regarding Tcis, if the image reading device 100 is warmed up at startup and used in a thermal equilibrium state, there is no need to monitor it (however, it is necessary to know the temperature at which the thermal equilibrium state is reached). Furthermore, since T' is the body temperature of the image reading device 100 measured on the mass production line, it is sufficient to record this in the storage unit 220 of the image reading device 100. The temperature Tcis used is the temperature in a thermal equilibrium state (input by the user).

[0132] Furthermore, when the cumulative physical length at a certain pixel position is P', and the body temperature of the image reading device 100 is Tcis, the cumulative physical length Ptemp taking into account the temperature dependency at that pixel position is expressed by the following equation (7): Ptemp=P'+ΔL (7)

[0133] In equation (7), P' and ΔL depend on the pixel position from the first pixel, so they can be calculated using the pixel position for which the positional deviation is desired. Here, ΔL also depends on Tcis, so ΔL is calculated by substituting the pixel position and Tcis into equation (6). In this way, the influence of temperature can be corrected using the temperature correction coefficient shown in equation (6) without measuring the temperature dependency of the positional deviation for each of the image reading devices 100. The temperature correction unit 56 corrects the cumulative physical length using equation (7).

[0134] Fig. 34 is a flowchart of the temperature correction process (step 6 in Fig. 14) using a temperature correction coefficient. More specifically, Fig. 34 shows a processing method for applying correction of the positional misalignment amount due to linear expansion to the relationship between pixel position and cumulative physical length derived in steps 1 to 5 in Fig. 14, based on data on changes in the positional misalignment amount with respect to temperature derived by the process shown in the flowchart in Fig. 28.

[0135] As mentioned above, the change in the amount of positional misalignment depends on the pixel position. The temperature correction process shown in FIG. 34 first requires the temperature at which the waveform data of the distance correction chart 25 of the image reading device 100 was measured, the temperature at which temperature correction is desired, and the temperature of the image reading device 100 (CIS) body at which the waveform data of the distance correction chart 25 was measured. The temperature T' at which the waveform data of the distance correction chart 25 was measured is pre-stored in the memory unit 220 of the distance measurement device 200 as the calibration temperature 81. The pixel position distance data generation unit 54 then adds or subtracts the amount of positional misalignment change ΔL calculated using the above equation (6) to or from the cumulative physical length (step S501), thereby completing the process. This process allows the number of pixels corresponding to the cumulative physical length, which is the physical spacing between black patterns on the distance correction chart, to be temperature-corrected. If this temperature correction process is not required, step 6 in FIG. 14 can be skipped.

[0136] The temperature correction process may not be performed in the pixel position distance data generation process, but may be temperature corrected for the distance between distance measurement points measured by the distance measurement unit 57. In this case, the temperature correction unit uses the temperature measured by the temperature sensor as the temperature Tcis.

[0137] The pixel position distance data may include, along with the pixel position, the amount of positional deviation at the pixel position, rather than the reference physical point distance at the pixel position. The amount of positional deviation is obtained by subtracting the pixel position difference distance, obtained by multiplying the pixel position difference, obtained by subtracting the reference pixel position from a certain pixel position, by the pixel size, from the reference physical point distance. The pixel position distance data may also include, along with the pixel position, the corrected reference physical point distance, obtained by subtracting the pixel position-dependent distance calculated from the pixel position difference from the reference physical point distance. The pixel position-dependent distance may be any distance that can be calculated from the pixel position using a predetermined calculation formula. The pixel position distance data includes, along with the pixel position, the corrected reference physical point distance or the stored reference physical point distance, which is the reference physical point distance.

[0138] Considering the case where pixel position distance data including a modified reference physical point distance is generated, the pixel position distance data generation unit generates pixel position distance data including a modified reference physical point distance obtained by subtracting a pixel position dependent distance calculated from the pixel position from the reference physical point distance, or a stored reference physical point distance which is the reference physical point distance.

[0139] When pixel position distance data including the corrected reference physical point distance is stored in the storage unit, the reference physical point distance calculation unit calculates the reference physical point distance by adding the pixel position dependent distance calculated from the pixel position to the stored reference physical point distance obtained by referring to the pixel position distance data. The temperature correction unit calculates the reference physical point distance and performs temperature correction on the reference physical point distance.

[0140] The flowchart in Figure 14 is a flowchart of a method for generating pixel position distance data to be used when measuring the distance in the main scanning direction between multiple specified points on a reading object, using an image reading device 100 that has multiple light receiving elements arranged in the main scanning direction, reads the reading object, converts the received light intensity, which is the intensity of light received by each light receiving element 15, into an electrical signal, and generates waveform data, which is a line image recorded for each pixel that corresponds to the arrangement position of each light receiving element in the main scanning direction, and a memory unit 220 that stores the waveform data.

[0141] Before step 1 is executed, a procedure is executed in which dark pattern arrangement information 74 is written to memory unit 220, the dark pattern arrangement information 74 including the physical width, which is the width of each dark pattern in distance correction chart 25, and the physical position, which is the position in the first direction, or information from which the physical position can be calculated, and the physical position is calculated. The dark patterns have a predetermined width in a first direction, are parallel to a second direction that is perpendicular to the first direction, and are arranged at predetermined intervals in the first direction, with light patterns that are greater than the dark lightness threshold and are greater than the light lightness threshold, which is determined between the dark patterns.

[0142] In step 1, three procedures are executed: a chart arrangement procedure for arranging the distance correction chart 25 so that the first direction is parallel to the main scanning direction, a procedure for writing chart waveform data 72, which is waveform data generated by reading the arranged distance correction chart with the image reading device 100, into the storage unit 220, and a procedure for converting the received light intensity of each pixel of the chart waveform data 72 into binarized chart waveform data stored as a binarized waveform 75, which is binarized based on a predetermined intensity threshold into dark values ​​representing received light intensity values ​​lower than the intensity threshold and bright values ​​representing received light intensity values ​​higher than the intensity threshold.

[0143] In step 2, a dark value pixel range determination procedure is executed to determine a dark value pixel range 76 in the binarized chart waveform data, which is a range of pixels sandwiched between two dark values ​​each having a light value adjacent to its outer edge, where the number of pixels included in the dark value pixel range matches the physical width of the self-dense pattern, which is the corresponding dense pattern included in the dense pattern arrangement information, taking into account the pixel size of the light receiving element, and the number of pixels between adjacent dark value pixel ranges matches the dense pattern physical spacing, which is determined based on the difference between the physical position of the self-dense pattern and the physical position of the adjacent dense pattern, which is the dense pattern corresponding to the adjacent dark value pixel range, taking into account the pixel size.

[0144] In step 3, a representative pixel position is determined for each dark value pixel range using the same determination method, and is expressed as a pixel position, which is the position of a pixel in the waveform data. A representative physical point corresponding to the representative pixel position is determined in the dark pattern corresponding to each dark value pixel range. One of the representative pixel positions is set as the reference pixel position, and the representative physical point corresponding to the reference pixel position is set as the reference physical point. The reference physical point distance, which is the distance between the representative physical point corresponding to each representative pixel position and the reference physical point, is calculated based on the physical position and physical width included in the dark pattern array information. For each representative pixel position, pixel position distance data 77 is generated, which includes the pixel position, which is the value of the representative pixel position, and the reference physical point distance.

[0145] In step 7, the procedure for writing the pixel position distance data 77 into the storage unit 220 is executed.

[0146] In the flowchart of FIG. 14 , the pixel position distance data generation unit 54 finally processes the output data (step 7 in FIG. 14 ). Because steps 1 through 6 were processed in the pixel position-cumulative physical length data format, skipping step 7 would result in the pixel position distance data 77 being obtained in the format output after step 6. However, since the pixel positions recorded in the pixel position distance data 77 are values ​​for each interval between the black lines 26 on the distance correction chart 25, the cumulative physical length is not recorded for every pixel position, which may make it less user-friendly. In such cases, the pixel position distance data can be converted into continuous data by converting the cumulative physical length into the positional misalignment amount and performing an approximate calculation for the pixels between adjacent lines, as performed in step 13 of FIG. 28 . In this way, the pixel position distance data generation unit 54 of the distance measurement device 200 converts the data into a data format convenient for the end user of the image reading device 100 and outputs the data (step 7 in FIG. 14 ).

[0147] The distance measurement unit 57 of the distance measurement device 200 uses the pixel position distance data 77 generated by the processing of the flowchart in Figure 14 to measure the distance between multiple points in the main scanning direction based on the waveform data obtained by reading the image of the measurement target with the image reading device 100.

[0148] Second Embodiment A second embodiment according to the present disclosure will be described with reference to the drawings.

[0149] Fig. 35 is a block diagram showing the configuration of a distance measurement device according to embodiment 2. Differences between Fig. 35 and Fig. 13 in embodiment 1 will be described below. A distance measurement device 200A has a modified processor 210A and a storage unit 220A. The processor 210A also operates as a decreased intensity pixel detection unit 58 and a decreased intensity pixel detection / notification unit 59. The storage unit 220A changes the operation mode 83A and also stores white waveform data 85 and decreased intensity pixel presence / absence information 86. The waveform data 71A also includes the white waveform data 85.

[0150] The operation mode 83A takes a value indicating a calibration mode, a measurement mode, and also a mode for checking whether the white output is normal (white output check mode). The white waveform data 85 is waveform data generated by the image reading device 100 reading the white chart 34 (not shown) when the operation mode 83A is the white output check mode, and written to the storage unit 220A by the waveform data acquisition unit 51. The presence or absence of reduced intensity pixels 86 is data indicating whether the white waveform data 85 contains pixels with reduced intensity.

[0151] The intensity-decreasing pixel detection unit 58 detects whether or not there are any pixels (intensity-decreasing pixels) in the white waveform data 85 whose received light intensity is less than a predetermined second intensity threshold. If the white waveform data 85 contains any intensity-decreasing pixels, the intensity-decreasing pixel detection unit 58 sets the intensity-decreasing pixel presence / absence field 86 to "yes." If the white waveform data 85 does not contain any intensity-decreasing pixels, the intensity-decreasing pixel detection unit 58 sets the intensity-decreasing pixel presence / absence field 86 to "no."

[0152] If the presence / absence of a pixel with a reduced intensity 86 indicates that there is a pixel with a reduced intensity, the pixel detection / notification unit 59 notifies the user that there is a pixel with a reduced intensity by displaying a message on the screen or the like.

[0153] Fig. 36 is a flowchart of pixel position distance data generation processing according to embodiment 2. The flowchart in Fig. 36 includes a white output confirmation step (step 101), a confirmation step (step 102) for the presence or absence of output reduction due to foreign matter such as dust, and a dust removal step (step 103) before the waveform capture to binarization processing (step 1) in the flowchart in Fig. 14.

[0154] In the first embodiment, the distance measurement device 200 generates pixel position distance data 77 for correcting the physical length in the main scanning direction of the image reading device 100 based on output data from the image reading device 100 that reads black and white patterns formed at equal intervals in the main scanning direction on the distance correction chart 25. However, if the distance correction chart 25 is read when the surface of the first transparent body 3 is dirty or has foreign matter attached thereto, the dirt or foreign matter on the surface of the first transparent body 3 will be erroneously recognized as black lines 26 on the distance correction chart 25.

[0155] Therefore, in the second embodiment, a white output confirmation step (step 101) is provided before the waveform capture to binarization process (step 1), and a white chart 34 for white luminance correction (for correcting the amount of light received by the light receiving element 15) is read in advance by the image reading device 100 to confirm the white output (white correction process).

[0156] If the surface of the first transparent body 3 is dirty or has foreign matter attached thereto, the light-receiving element 15 corresponding to that location will receive a reduced amount of light. Therefore, the intensity-decreased pixel detection unit 58 determines the surface condition of the first transparent body 3 in an output reduction confirmation step (step 102). If there is data from the light-receiving element 15 indicating a reduced amount of light (light-receiving data indicating a reduced white output) (step 102: Yes), it is determined that the surface of the first transparent body 3 is dirty or has foreign matter attached thereto, and the intensity-decreased pixel detection unit 58 sets the intensity-decreased pixel presence / absence field 86 to "yes." The intensity-decreased pixel detection notification unit 59 then notifies the user of the presence of an intensity-decreased pixel by displaying a message on the screen or the like. The user then proceeds to a dust removal step (step 103) of the image reading device 100. In step 103, the user cleans the first transparent body 3, and the process returns to the white output confirmation step (step 101). If there is no light reception data from the light receiving element 15 that reduces the amount of received light (step 102: No), the intensity-decreased pixel detection unit 58 determines that the surface of the first transparent body 3 is normal, with no dirt or foreign matter attached, and proceeds to waveform capture and binarization processing (step 1). Note that the process may proceed to step 1 after the user cleans the first transparent body 3 in step 103. The distance measurement device 200A can operate in calibration mode by reading the distance correction chart even if it cannot confirm that there are no intensity-decreased pixels.

[0157] By carrying out the above steps (steps 101 to 103), reading errors of the distance correction chart 25 can be prevented.

[0158] The white waveform data 85 may be displayed on a screen to the user to allow the user to determine whether or not there are any reduced intensity pixels.

[0159] The white chart 34 may be a light gray or yellow chart. It is sufficient that the white chart 34 is a light pattern chart that has a uniform brightness greater than a predetermined brightness threshold. In the white output confirmation mode, the light pattern chart is placed as the reading target, and the image reading device 100 reads it to generate the white waveform data 85. The white waveform data 85 is light pattern waveform data that is generated by reading the light pattern chart placed as the reading target with the line image reading unit, and is written to the memory unit 220A by the waveform data acquisition unit 51.

[0160] The flowchart in FIG. 36 is a flowchart of a method for generating pixel position distance data using an image reading device 100 having a first transparent body 3 (transparent body) between the reading object and the light receiving element 15.

[0161] In step 101, the following steps are executed: a light pattern chart having a uniform brightness greater than a predetermined brightness threshold is placed as the object to be read; and white waveform data 85, which is waveform data generated by the image reading device 100 reading the placed light pattern chart, is written to memory unit 220A.

[0162] In step 102, a procedure for detecting pixels with reduced intensity is performed to determine whether there are any pixels in the white waveform data 85 whose received light intensity is less than a predetermined second intensity threshold.

[0163] In step 103, if there is a pixel whose received light intensity is smaller than the second intensity threshold, a cleaning procedure is executed in which the user cleans the surface of the first transparent body 3 (transparent body).

[0164] If there are no pixels with received light intensity less than the second intensity threshold, or after the cleaning procedure, the chart placement procedure is performed in step 1.

[0165] In the above, when it is determined that the surface of the first transparent body 3 is dirty or that foreign matter is attached, the image reading device 100 proceeds to the dust removal step (step 103) and cleans the first transparent body 3. However, the processor 210 may set the data of the light receiving element 15 where the amount of received light has decreased as invalid data in the output reduction confirmation step (step 102), and proceed to waveform capture and binarization processing (step 1). In this case, the data of the light receiving element 15 is treated as invalid data in the subsequent steps.

[0166] First Modification The first modification is a modification of the second embodiment in which the binarized waveform converter 52, edge information converter 53, and pixel position distance data generator 54 operate only when the presence / absence of intensity-decreased pixels 86 is absent.

[0167] Figure 37 is a block diagram showing the configuration of a distance measurement device according to a first modification of embodiment 2. Differences between Figure 37 and Figure 35 in embodiment 2 will be described below. Distance measurement device 200B has modified processor 210B and storage unit 220B. Processor 210B has modified binarized waveform conversion unit 52B, edge information conversion unit 53B, pixel position distance data generation unit 54B, and intensity drop pixel detection unit 58B. Storage unit 220B also stores operation control flag 87. Operation control flag 87 takes the value of either operation stopped or operation enabled.

[0168] When setting the presence / absence of intensity-decreased pixels 86 to "present," the intensity-decreased pixel detection unit 58B sets the operation control flag 87 to "inoperative." When setting the presence / absence of intensity-decreased pixels 86 to "absent," the intensity-decreased pixel detection unit 58B sets the operation control flag 87 to "enabled."

[0169] The binary waveform converter 52B, the edge information converter 53B, and the pixel position distance data generator 54B refer to the operation control flag 87, and operate only when the operation control flag 87 is operable. In the distance measurement device 200B, the processor 210B operates as the binary waveform converter 52B, the edge information converter 53B, and the pixel position distance data generator 54B when the operation control flag 87 is operable, and does not operate as the binary image data converter 52B, the edge information converter 53B, and the pixel position distance data generator 54B when the operation control flag 87 is inoperative.

[0170] The storage unit 220 may be configured not to store the operation control flag 87, and the presence / absence of intensity-decreased pixels 86 may also function as the operation control flag. In this case, the binarized waveform conversion unit 52B, the edge information conversion unit 53B, and the pixel position distance data generation unit 54B refer to the presence / absence of intensity-decreased pixels 86, and operate when the presence / absence of intensity-decreased pixels 86 is not present. The binarized waveform conversion unit 52B, the edge information conversion unit 53B, and the pixel position distance data generation unit 54B do not operate when the presence / absence of intensity-decreased pixels 86 is present.

[0171] Second Modification The second modification is a modification of the second embodiment in which, when a pixel with reduced intensity is detected, the pixel position of the pixel with reduced intensity is stored as an invalid pixel position, and the edge information conversion unit 53 determines the dark value pixel range without recognizing the pixel at the pixel position stored as the invalid pixel position as either a dark value or a bright value.

[0172] FIG. 38 is a block diagram showing the configuration of a distance measurement device 200C according to a second modification of the second embodiment. Differences between FIG. 38 and FIG. 35 in the second embodiment will be described. The distance measurement device 200C has modified processor 210C and storage unit 220C. The processor 210C has modified binarized waveform conversion unit 52C and edge information conversion unit 53C. It does not operate as the intensity-decreased pixel detection unit 58 or the intensity-decreased pixel detection / notification unit 59, but operates as an invalid pixel position detection unit 60. The storage unit 220C does not store the intensity-decreased pixel presence / absence information 86 and the operation control flag 87, but stores an invalid pixel position 88. The waveform has been changed to a binarized waveform 75C.

[0173] The invalid pixel positions 88 are data obtained by processing similar to that of the binarized waveform 75. At pixel positions in the white waveform data 85 where the received light intensity is less than a predetermined second intensity threshold, "0" representing invalidity is set at the invalid pixel positions 88. At pixel positions in the white waveform data 85 where the received light intensity is equal to or greater than the predetermined second intensity threshold, "1" representing validity is set at the invalid pixel positions 88.

[0174] The binarized waveform 75C also stores an invalid value that is neither a dark value nor a bright value. The invalid value is, for example, "2." The invalid value is not recognized as either a dark value or a bright value by the edge information conversion unit 53C.

[0175] The invalid pixel position detection unit 60 processes the white waveform data 85 to detect invalid pixel positions, and writes the detected invalid pixel positions to the storage unit 220C as invalid pixel positions 88. The invalid pixel position detection unit 60 checks whether the received light intensity of each pixel of the white waveform data 85 is smaller than a predetermined second intensity threshold, and sets "0" representing invalid at the invalid pixel position 88 at pixel positions where the received light intensity is smaller than the second intensity threshold. The invalid pixel position detection unit 60 sets "1" representing valid at the invalid pixel position 88 at pixel positions where the received light intensity is equal to or greater than the second intensity threshold.

[0176] The binarized waveform converter 52C generates a binarized waveform 75C by referring to the chart waveform data 72 and the invalid pixel positions 88. The binarized waveform converter 52C checks whether each pixel position in the chart waveform data 72 is invalid at the invalid pixel positions 88. The binarized waveform converter 52C sets an invalid value in the binarized waveform 75C at invalid pixel positions. At pixel positions that are not invalid, the binarized waveform converter 52C sets a dark value or a bright value, which is determined by comparing the received light intensity of the chart waveform data 72 with an intensity threshold, to the binarized waveform 75C.

[0177] The edge information conversion unit 53C recognizes a portion of the binary waveform 75C where the x-coordinate changes from a bright value to a dark value in the direction of increase as a falling edge, and a portion where the x-coordinate changes from a dark value to a bright value as a rising edge. The edge information conversion unit 53C does not recognize a portion where the x-coordinate changes from a dark value to an invalid value, a portion where the x-coordinate changes from a bright value to an invalid value, a portion where the x-coordinate changes from an invalid value to a dark value, or a portion where the x-coordinate changes from an invalid value to a bright value as a falling edge or a rising edge.

[0178] Third Embodiment A third embodiment of the present disclosure will be described with reference to the drawings.

[0179] Fig. 36 is a processing flowchart for waveform data of a distance correction chart according to embodiment 3. In the processing flowchart of Fig. 36, a process for determining whether or not a lens joint is present (step 301) and a process for invalidating the measurement correction value near the lens joint (step 302) are provided between the temperature correction process (step 6) and the output data process (step 7) in the flowchart of Fig. 14 .

[0180] In the case of an image reading device 100 that is long in the main scanning direction, one rod lens array 11 cannot cover the image reading range, so several rod lens arrays 11 are sometimes joined together in the main scanning direction as shown in Figure 39. Figure 39 shows a case in which a rod lens array 11A and a rod lens array 11B are joined together in the main scanning direction.

[0181] When multiple rod lens arrays 11 (11A, 11B) are joined in the main scanning direction, the rod lenses 11A and 11B are joined using a sealant 111. At the joint between the rod lenses 11A and 11B, which includes the sealant 111, a joining error may occur between the two joined rod lens arrays 11 (11A, 11B). As shown in FIG. 40 , in the image reading device 100, the rod lens arrays 11 (11A, 11B) are pressed against the plate 31 in the sub-scanning direction by the lens plate 112 and the adjustment screw 113, so that no misalignment occurs in the sub-scanning direction (Y direction) at the joint. For the same reason, no misalignment occurs in the main scanning direction (X direction).

[0182] However, in the direction perpendicular to the main scanning direction and the sub-scanning direction, a joining error may occur in the rod lens array 11 (11A, 11B) at the joint. Specifically, as shown in Figure 41, in the rod lenses 16 adjacent to each other across the joint, the distance between the optical axes may differ between one end (e.g., the light entrance portion) and the other end (e.g., the light exit portion).

[0183] In rod lens 16 at the joint, if the distance between the optical axes is the same at one end (e.g., the light entrance portion) and the other end (e.g., the light exit portion) (Figure 41(a)), measurement correction of image reading device 100 is possible using steps 1 to 6 in Figure 36, as in embodiment 1.

[0184] However, if the distance between the optical axes of one end (e.g., the light entrance end) and the other end (e.g., the light exit end) of the rod lens 16 at the joint is different (Figure 41(b)), the length measurement correction value at the joint may show a singular point (discontinuity point), as shown in Figure 42.

[0185] Therefore, the processor 210 invalidates the data near the joint of the rod lens array 11 (11A, 11B) where the measurement correction value may show a singularity (for example, forcibly inputs FAULT-DATA), and proceeds to output data processing (step 7).

[0186] Since the positions of the joints between the rod lens arrays 11 (11A, 11B) are known in advance, the light reception data from a predetermined number of light receiving elements 15, including the joints, is invalidated. For example, pixel position distance data for pixels of 50 elements in front and behind in the main scanning direction (i.e., 100 elements in total) is invalidated (for example, FAULT-DATA is forcibly input), and the process proceeds to output data processing (step 7).

[0187] That is, if the image reading device 100 is configured in advance with a plurality of rod lens arrays 11 connected in the main scanning direction, the lens joint presence / absence determination process determines "present" (step S301: Yes), and the processor 210 of the distance measurement device 200 performs a process of invalidating the length measurement correction values ​​near the lens joints (step S302). Specifically, pixel position distance data from a predetermined number of light receiving elements 15 including pixels corresponding to the joints of the rod lens arrays 11 is invalidated, and the process proceeds to output data processing (step S7).

[0188] If the image reading device 100 is composed of one rod lens array 11, the distance measurement device 200 determines that there is no lens joint in the lens joint presence / absence processing (step 301: No), and proceeds to output data processing (step 7), where the measurement results of the distance between multiple points in the main scanning direction are output using the results obtained in step 6.

[0189] The configuration of a distance measurement device 200D according to the third embodiment will be described with reference to Fig. 43. Fig. 43 is a block diagram showing the configuration of a distance measurement device 200D according to the third embodiment. Regarding Fig. 43, differences from Fig. 35 in the case of the second embodiment will be described. The distance measurement device 200D has modified processor 210D and storage unit 220D. The processor 210D has modified distance measurement unit 57D. The storage unit 220D also stores a second invalid pixel position range 89.

[0190] The second invalid pixel position range 89 is a range of a predetermined number of pixels including pixels facing the junction of the rod lens array 11. The second invalid pixel position range 89 is expressed as data in the same format as the invalid pixel position 88. In the second invalid pixel position range 89, a normal value indicating normality, such as "0," is set at pixel positions that are not invalid. In the second invalid pixel position range 89, an invalid value that is not a normal value, such as FAULT-DATA, is set at pixel positions that are invalid. Regarding whether a non-integer pixel position xx is included in the second invalid pixel position range 89, the pixel position xx is considered invalid if at least one of the pixel positions on either side of the pixel position xx is set to an invalid value. The pixel position xx is considered valid if both pixel positions on either side of the pixel position xx are not invalid values. The second invalid pixel position range 89 may be expressed as a pair of a start pixel position and an end pixel position.

[0191] The distance measurement unit 57D calculates and outputs the object distance between a plurality of points in the main scanning direction using pixel position distance data 77, based on distance measurement waveform data 73 obtained by reading the distance measurement object with the image reading device 100. However, for distance measurement points corresponding to distance measurement pixel positions included in the second invalid pixel position range 89 among the plurality of distance measurement points, the distance between the distance measurement points is not measured.

[0192] The distance measurement unit 57D determines distance measurement pixel positions, which are pixel positions corresponding to each distance measurement point, based on the distance measurement point information, and checks whether the distance measurement pixel positions are included in the second invalid pixel position range 89. For distance measurement pixel positions included in the second invalid pixel position range 89, the reference physical point distance is not calculated. Furthermore, the distance between the corresponding distance measurement point and another distance measurement point is not calculated. For distance measurement pixel positions not included in the second invalid pixel position range 89, the reference physical point distance is calculated. The distance measurement unit 57D calculates the reference physical point distance between the distance measurement point for which the reference physical point distance has been calculated and the distance measurement points for which other reference physical point distances have been calculated.

[0193] By performing the above processing, it is possible to perform length measurement correction for the image reading device 100 even when the image reading device 100 is configured with a plurality of rod lens arrays 11 connected in the main scanning direction.

[0194] Various aspects of the present disclosure are summarized below as appendices.

[0195] (Supplementary Note 1) A line image reading unit has a plurality of light receiving elements arranged in a main scanning direction, and reads a read target, converts received light intensity, which is the intensity of light received by each of the light receiving elements, into an electrical signal, and generates waveform data, which is a line image recorded for each pixel associated with the arrangement position of each of the light receiving elements in the main scanning direction; a storage unit; and a processor, wherein the storage unit stores: the waveform data; dark pattern arrangement information, which includes: a physical width, which is the width of each of the dark patterns, and a physical position, which is a position in the first direction, of each of the dark patterns in a distance correction chart having a predetermined length in the first direction, the dark patterns being parallel to a second direction that is perpendicular to the first direction, the dark patterns having a lightness less than a predetermined dark lightness threshold, and arranged at predetermined intervals in the first direction, with light patterns having a lightness greater than a light lightness threshold that is greater than the dark lightness threshold, arranged between the dark patterns; the processor stores distance measurement point information, which is information about distance measurement points included in a distance measurement object that is a reading object and includes distance measurement points, which are a plurality of points that are objects for measuring distance in the main scanning direction, and pixel position distance data used when measuring a distance between the distance measurement points, and the processor includes: a waveform data acquisition unit that acquires the waveform data generated by the line image reading unit from the line image reading unit and writes it into the storage unit; a binary image data conversion unit that converts the received light intensity of each pixel of chart waveform data, which is the waveform data generated by the line image reading unit reading the distance correction chart that is the reading object arranged so that the first direction is parallel to the main scanning direction, into binary chart waveform data that is binarized based on a determined intensity threshold into a dark value that indicates that the received light intensity is lower than the intensity threshold and a light value that indicates that the received light intensity is higher than the intensity threshold;a dark value pixel range determination unit that determines, in the binarized chart waveform data, a dark value pixel range that is a range of pixels sandwiched between two dark values ​​each having an adjacent bright value on the outside, wherein the number of pixels included in the dark value pixel range matches the physical width of the self-dense pattern that is the corresponding dense pattern included in the dense pattern arrangement information, taking into account the pixel size of the light receiving element, and the number of pixels between adjacent dark value pixel ranges matches a dense pattern physical interval that is determined based on the difference between the physical position of the adjacent dense pattern that is the dense pattern corresponding to the adjacent dark value pixel range and the physical position of the self-dense pattern, taking into account the pixel size; a pixel position distance data generation unit that determines, for each of the dark value pixel ranges, a representative pixel position expressed as a pixel position that is the position of a pixel in the waveform data using the same determination method, determines a representative physical point that corresponds to the representative pixel position in the dark pattern that corresponds to each of the dark value pixel ranges, sets one of the representative pixel positions as a reference pixel position, sets the representative physical point that corresponds to the reference pixel position as a reference physical point, calculates a reference physical point distance that is the distance between the representative physical point that corresponds to each of the representative pixel positions and the reference physical point based on the physical position and the physical width included in the dark pattern array information, and generates, for each of the representative pixel positions, pixel position distance data that includes the pixel position that is the value of the representative pixel position and a corrected reference physical point distance obtained by subtracting a pixel position-dependent distance calculated from the pixel position from the reference physical point distance, or a stored reference physical point distance that is the reference physical point distance, and writes the pixel position distance data into the storage unit; a reference physical point distance calculation unit that calculates the reference physical point distance at the input pixel position by referring to the pixel position distance data;a reference physical point distance calculation unit that calculates a reference physical point distance for each of the distance measurement pixel positions, and measures an absolute value of a difference between the reference physical point distances at the calculated distance measurement pixel positions as the distance between the distance measurement points. (Supplementary Note 2) When operating as the dark value pixel range determination unit, the processor uses a matching determination condition that is a condition for determining that each of the dark value pixel ranges matches the corresponding dark value pattern, and the matching determination condition includes a width pixel number condition that determines whether a width pixel number range determined to include a value obtained by dividing the physical width of the corresponding dark value pattern by the pixel size is included in the number of pixels present in each of the dark value pixel ranges. (Supplementary Note 3) The distance measurement device according to Supplementary Note 2, wherein the matching determination conditions include an interval pixel number condition that determines whether, for each combination of two adjacent dark value pixel ranges, an interval pixel number range that is determined to include a value obtained by dividing the dark pattern physical interval between two dark patterns corresponding to each of the two dark value pixel ranges by the pixel size includes the number of pixels between the two adjacent dark value pixel ranges. (Supplementary Note 4) The distance measurement device according to Supplementary Note 3, wherein the matching determination conditions include an edge pixel range condition that determines whether one dark value pixel range is included in each of a predetermined number of edge pixel ranges that are ranges of pixels determined at both ends of the plurality of light receiving elements arranged in the main scanning direction, and the edge pixel range condition is satisfied when one dark value pixel range is included in each of the edge pixel ranges, and the edge pixel range condition is not satisfied when there is an edge pixel range that does not include any of the dark value pixel ranges. (Supplementary Note 5) The distance measurement device according to any one of Supplementary Note 1 to Supplementary Note 4, wherein the processor, when operating as the pixel position distance data generation unit, sets, for each of the dark value pixel ranges, an average of the pixel positions of the dark values ​​at both ends of the dark value pixel range as the representative pixel position.The memory unit further stores invalid pixel positions, which are the pixel positions of pixels that are not recognized as either the dark value or the bright value; the processor also operates as an invalid pixel position detection unit that writes, as the invalid pixel positions, the pixel positions of pixels whose received light intensity of each pixel of light pattern waveform data, which is the waveform data that the line image reading unit reads and generates from a light pattern chart arranged as the reading target and has a uniform brightness greater than a determined brightness threshold, and which is written to the memory unit by the waveform data acquisition unit, smaller than a determined second intensity threshold; and when operating as the dark value pixel range determination unit, the processor determines the dark value pixel range without recognizing the pixel at the pixel position written at the invalid pixel position as either the dark value or the bright value. (Supplementary Note 7) The distance measurement device according to any one of Supplementary Notes 1 to 6, wherein the memory unit further stores a second invalid pixel position range which is a range of the pixel positions in which the distance between the distance measurement points is not calculated, and the processor, when operating as the distance measurement unit, does not calculate the distance between the distance measurement points for the distance measurement points corresponding to the distance measurement pixel positions included in the second invalid pixel position range. (Supplementary Note 8) The distance measurement device according to any one of Supplementary Notes 1 to 7, wherein the memory unit further stores a calibration temperature which is the temperature of the line image reading unit when the chart waveform data is read to generate the pixel position distance data, and a temperature correction coefficient, and the processor operates as a temperature correction unit that processes so that the distance between the distance measurement points corrected based on the difference between the temperature of the line image reading unit and the calibration temperature and the temperature correction coefficient can be measured. (Supplementary Note 9) When a correctable length, which is the length in the main scanning direction of a correctable range that is a range sandwiched between the dark patterns arranged at both ends in the main scanning direction in the distance correction chart, is shorter than an effective reading length, which is the length in the main scanning direction of a reading range that is a range in which the light receiving elements of the line image reading unit are arranged,the distance measurement device according to any one of Supplementary Note 1 to Supplementary Note 8, wherein chart placement positions, which are positions in the main scanning direction at which the distance correction chart is placed, are determined to have portions where the correctable ranges at adjacent chart placement positions overlap, and a correctable sum range, which is the sum of the correctable ranges at each of the chart placement positions, includes the reading range, or the length in the main scanning direction of a non-correction range, which is a range that is included in the reading range but not included in the correctable sum range, is equal to or less than a determined upper limit value of the non-correction range length; and the processor operates as the binary image data conversion unit, the dark value pixel range determination unit, and the pixel position distance data generation unit at each of the chart placement positions, and generates the pixel position distance data including pixel positions obtained at each of the chart placement positions and the reference physical point distance relative to the common reference physical point. (Supplementary Note 10) The distance measurement device according to Supplementary Note 9, wherein, at each of the two adjacent chart placement positions, a first chart placement position and a second chart placement position, the processor operates as the pixel position distance data generation unit to generate pixel position distance data belonging to a first pixel position distance data set and a second pixel position distance data set, which are sets of pixel position distance data, so that the pixel position distance data belonging to the first pixel position distance data set and the second pixel position distance data set have the reference physical point distance to the common reference physical point, uses a first range second pixel position reference physical point distance, which is the reference physical point distance to the reference physical point in the pixel position distance data belonging to the first pixel position distance data set, for a first range second pixel position that has the pixel position included in a first pixel position definition range, which is a range of pixel positions included in any of the pixel position distance data belonging to the first pixel position distance data set, and is included in the pixel position distance data belonging to the second pixel position distance data set. (Supplementary Note 11) When the processor causes each of the pixel position distance data belonging to a first pixel position distance data set and a second pixel position distance data set, which are sets of pixel position distance data generated by the pixel position distance data generating unit, at each of the first chart placement position and the second chart placement position, which are two adjacent chart placement positions, to have the reference physical point distance from the reference physical point in common,10. The distance measurement device according to claim 9, further comprising: a first boundary pixel position, which is the pixel position at the end of a first pixel position definition range, which is the range of pixel positions included in any of the pixel position distance data belonging to the first pixel position distance data set, on the side where each of the pixel position distance data belonging to the second pixel position distance data set exists; a first adjacent second pixel position, which is the pixel position included in the pixel position distance data belonging to the second pixel position distance data set and has an adjacent minimum pixel position difference that is the minimum value of the difference between the first boundary pixel position and the pixel position, and is the same pixel position as the first boundary pixel position or a pixel position that is not included in the first pixel position definition range; and an adjacent pixel position difference distance obtained by multiplying the adjacent minimum pixel position difference by the pixel size. (Appendix 12) The processor is a distance measurement device described in any one of Appendices 1 to 11, wherein the processor also operates as an intensity-reduced pixel detection unit that detects whether there are any pixels in the light pattern waveform data, which is the waveform data generated by the line image reading unit reading a light pattern chart arranged as the reading target and which has a uniform brightness greater than a predetermined brightness threshold, and which has the received light intensity of each pixel less than a predetermined second intensity threshold, and which is written to the memory unit by the waveform data acquisition unit; and an intensity-reduced pixel detection notification unit that, if there are any pixels whose received light intensity is less than the second intensity threshold, notifies the user that there are any pixels whose received light intensity is less than the second intensity threshold. (Supplementary Note 13) The storage unit also stores an operation control flag that takes a value of inoperative or operable, and when operating as the intensity-decreased pixel detection unit, the processor sets the operation control flag to inoperative if there is a pixel whose received light intensity is smaller than the second intensity threshold, and sets the operation control flag to operable if there is no pixel whose received light intensity is smaller than the second intensity threshold, and when the operation control flag is operable, the processor operates as the binary image data conversion unit, the dark value pixel range determination unit, and the pixel position distance data generation unit,The distance measurement device according to claim 12, wherein when the operation control flag is set to operation stop, the processor does not operate as the binary image data conversion unit, the dark value pixel range determination unit, or the pixel position distance data generation unit. (Supplementary note 14) The distance measurement device according to any one of Supplementary notes 1 to 13, when operating as the reference physical point distance calculation unit, calculates the reference physical point distance for the input pixel position based on a pixel position distance graph that connects, by a straight line or a curve, two points corresponding to the pixel position distance data that are adjacent to the pixel position in a two-dimensional plane of the pixel position and the reference physical point distance. (Supplementary Note 15) A method for generating pixel position distance data to be used when measuring distances in the main scanning direction between predetermined points on the object to be read, using a line image reading unit having a plurality of light receiving elements arranged in a main scanning direction, the line image reading unit reading an object to be read and converting received light intensity, which is the intensity of light received by each of the light receiving elements, into an electrical signal to generate waveform data, which is a line image recorded for each pixel associated with an arrangement position of each of the light receiving elements in the main scanning direction, and a storage unit storing the waveform data, the method comprising the steps of: writing into the storage unit dark pattern arrangement information, the dark patterns having a predetermined length in a first direction, the dark patterns having a predetermined width in a first direction and parallel to a second direction perpendicular to the first direction, the dark patterns having a lightness less than a predetermined dark lightness threshold, arranged at predetermined intervals in the first direction, and light patterns having a lightness greater than a light lightness threshold and greater than the dark lightness threshold, arranged between the dark patterns; a step of writing chart waveform data, which is the waveform data generated by reading the distance correction chart with the line image reading unit, into the storage unit, in a state in which the distance correction chart is arranged so that the first direction is parallel to the main scanning direction; and a step of converting the received light intensity of each pixel of the chart waveform data into binarized chart waveform data, which is binarized based on a predetermined intensity threshold into dark values ​​representing that the received light intensity is lower than the intensity threshold and light values ​​representing that the received light intensity is higher than the intensity threshold.a dark value pixel range determination step for determining, in the binarized chart waveform data, a dark value pixel range that is a range of pixels sandwiched between two dark values ​​each having an adjacent bright value on the outside, wherein the number of pixels included in the dark value pixel range is consistent with the physical width of the self-dense pattern that is the corresponding dense pattern included in the dense pattern arrangement information, taking into account the pixel size of the light receiving element, and the number of pixels between adjacent dark value pixel ranges is consistent with a dense pattern physical interval that is determined based on the difference between the physical position of the self-dense pattern and the physical position of the adjacent dense pattern that is the dense pattern corresponding to the adjacent dark value pixel range, taking into account the pixel size; a representative physical point corresponding to the representative pixel position in the dark pattern corresponding to each of the dark value pixel ranges, using the same determination method; determining a representative physical point corresponding to the representative pixel position in the dark pattern corresponding to each of the dark value pixel ranges; setting one of the representative pixel positions as a reference pixel position and the representative physical point corresponding to the reference pixel position as a reference physical point; calculating a reference physical point distance, which is the distance between the representative physical point corresponding to each of the representative pixel positions and the reference physical point, based on the physical position and the physical width included in the dark pattern array information; and generating pixel position distance data for each of the representative pixel positions, which includes the pixel position that is the value of the representative pixel position and a modified reference physical point distance obtained by subtracting a pixel position-dependent distance calculated from the pixel position from the reference physical point distance, or a stored reference physical point distance that is the reference physical point distance; and writing the pixel position distance data to the storage unit. (Supplementary Note 16) A method for generating pixel position distance data using the line image reading unit having a transparent body between the reading target and the light receiving element, comprising the steps of: placing a light pattern chart having a uniform lightness greater than a predetermined lightness threshold as the reading target; and writing light pattern waveform data, which is the waveform data generated by reading the light pattern chart with the line image reading unit, into the storage unit; and a step of detecting pixels with reduced intensity, which determines whether or not there is a pixel in the light pattern waveform data whose received light intensity is less than a predetermined second intensity threshold.a cleaning step in which a user cleans the surface of the transparent body when a pixel having the received light intensity smaller than the second intensity threshold exists, and the chart arrangement step is executed when no pixel having the received light intensity smaller than the second intensity threshold exists or after the cleaning step. (Supplementary Note 17) The pixel position distance data generation method according to Supplementary Note 15 further comprises the steps of: a step of writing, into the storage unit, light pattern waveform data, which is the waveform data generated by reading a light pattern chart having a uniform lightness greater than a predetermined lightness threshold, with the light pattern chart arranged as the reading target, and a step of checking whether the received light intensity of each pixel of the light pattern waveform data is smaller than a predetermined second intensity threshold, and writing, into the storage unit, invalid pixel positions, which are the pixel positions of pixels having the received light intensity smaller than the second intensity threshold; and (Supplementary Note 18) A computer having a storage unit and a processor connected to a line image reading unit that has a plurality of light receiving elements arranged in a main scanning direction, that reads an object to be read, converts received light intensity, which is the intensity of light received by each of the light receiving elements, into an electrical signal, and generates waveform data, which is a line image recorded for each pixel associated with an arrangement position of each of the light receiving elements in the main scanning direction, wherein the storage unit stores dark pattern arrangement information, which includes a physical width, which is the width of each of the dark patterns, and a physical position, which is a position in the first direction, or information that can calculate the physical position, in a distance correction chart having a predetermined length in the first direction, in which a plurality of dark patterns having a lightness less than a predetermined dark lightness threshold and parallel to a second direction that is perpendicular to the first direction, are arranged at predetermined intervals in the first direction, and light patterns having a lightness greater than a light lightness threshold that is greater than the dark lightness threshold are arranged between the dark patterns, a waveform data acquisition unit that acquires the waveform data generated by the line image reading unit from the line image reading unit and writes the waveform data into the storage unit;a binary image data conversion unit that converts the received light intensity of each pixel of chart waveform data, which is the waveform data written to the storage unit by the waveform data acquisition unit, into binary chart waveform data, which is generated by reading the distance correction chart, which is the reading target, arranged so that the first direction is parallel to the main scanning direction, using a determined intensity threshold as a reference, into dark values ​​that represent that the received light intensity is lower than the intensity threshold and light values ​​that represent that the received light intensity is higher than the intensity threshold; a dark value pixel range determination unit that determines, in the binarized chart waveform data, a dark value pixel range that is a range of pixels sandwiched between two dark values ​​each having an adjacent bright value on the outside, wherein the number of pixels included in the dark value pixel range matches the physical width of the corresponding self-dense pattern that is included in the dense pattern arrangement information, taking into account the pixel size of the light receiving element, and the number of pixels between adjacent dark value pixel ranges matches a dense pattern physical interval that is determined based on the difference between the physical position of the adjacent dense pattern that is the dense pattern corresponding to the adjacent dark value pixel range and the physical position of the self-dense pattern, taking into account the pixel size; and a computer-readable recording medium having the program according to claim 18 recorded thereon, for operating as a pixel position distance data generating unit that determines, for each of the dark value pixel ranges, a representative pixel position expressed as a pixel position that is a pixel position in the waveform data using the same determination method, determines a representative physical point that corresponds to the representative pixel position in the dark pattern that corresponds to each of the dark value pixel ranges, sets one of the representative pixel positions to a reference pixel position, sets the representative physical point that corresponds to the reference pixel position to a reference physical point, calculates a reference physical point distance that is the distance between the representative physical point that corresponds to each of the representative pixel positions and the reference physical point based on the physical position and the physical width included in the dark pattern array information, and generates pixel position distance data for each of the representative pixel positions that includes the pixel position that is the value of the representative pixel position, and a corrected reference physical point distance obtained by subtracting a pixel position-dependent distance calculated from the pixel position from the reference physical point distance, or a stored reference physical point distance that is the reference physical point distance, and writes the pixel position distance data to the storage unit.

[0196] The present disclosure allows various embodiments and modifications without departing from the broad spirit and scope of the present disclosure. Furthermore, the above-described embodiments are intended to explain the present disclosure and do not limit the scope of the present disclosure. That is, the scope of the present disclosure is defined by the claims, not the embodiments. Various modifications made within the scope of the claims and within the meaning of the disclosure equivalent thereto are considered to be within the scope of the present disclosure.

[0197] This application is based on Japanese Patent Application No. 2024-009960, filed on January 26, 2024, and International Application No. PCT / JP2024 / 014640, filed on April 11, 2024. The entire specifications, claims, and drawings of Japanese Patent Application No. 2024-009960 and International Application No. PCT / JP2024 / 014640 are incorporated herein by reference.

[0198] 100 Image reading device (line image reading unit), 2 Side plate, 3 First transparent body (transparent body), 4 Chart, 5 Output waveform of chart 4, 7 Second frame, 8 Light source, 9 First frame, 10 Second transparent body, 11, 11A, 11B Rod lens array, 12 Substrate support plate, 13 Substrate, 14 Substrate, 15 Light receiving element, 16 Rod lens, 17 Fixed side plate, 18 Original, 19 Erect life-size image of original 18, 20 Table with ensured flatness, 21 Fixture, 22 Fixture, 23 Infrared sensor, 24 Rail, 25 Distance correction chart, 26 Black line, 27 White plain area, 28 Black scratch, 29 Second effective start black line, 30 First effective final black line, 31 Plate, 32 First pixel position definition range, 33, 33 1 , 33 2 , 33 3 , 33 4First range second black line, 34 white chart (light pattern chart), 51 waveform data acquisition unit, 52, 52B binary waveform conversion unit, 53, 53B edge information conversion unit (dark value pixel range determination unit), 54, 54B pixel position distance data generation unit, 55 reference physical point distance calculation unit, 56 temperature correction unit, 57, 57D distance measurement unit, 58, 58B intensity drop pixel detection unit, 59 intensity drop pixel detection notification unit, 60 invalid pixel position detection unit, 71, 71A waveform data, 72 chart waveform data, 73 distance measurement waveform data, 74 dark pattern arrangement information, 75, 75C binary waveform (binarized chart waveform data), 76 edge information (dark value pixel range), 77 pixel position distance data, 78 pixel size, 79 distance measurement point information, 80 distance between distance measurement points, 81 calibration temperature, 82 temperature correction coefficient, 83, 83A operation mode, 84 edge detection data (dark pattern arrangement information), 85 white waveform data (light pattern waveform data), 86 presence or absence of intensity-decreased pixels, 87 operation control flag, 88 invalid pixel position, 89 second invalid pixel position range, 111 sealing material, 112 lens plate, 113 adjustment screw, 200, 200A, 200B, 200C, 200D distance measurement device, 210, 210A, 210B, 210C, 210D processor, 220, 220A, 220B, 220C, 220D storage unit.

Claims

1. A line image reading unit having a plurality of light receiving elements arranged in a main scanning direction, reading a reading target, converting a light receiving intensity, which is the intensity of light received by each of the light receiving elements, into an electrical signal, and generating waveform data which is a line image recorded for each pixel associated with the arrangement position of each of the light receiving elements in the main scanning direction; a storage unit; and a processor, wherein the storage unit stores: the waveform data; density pattern array information including a physical width which is the width of each of the density patterns in a distance correction chart having a length determined in a first direction, and a physical position which is a position in the first direction, or information capable of calculating the physical position, the density pattern array information having a plurality of density patterns arranged at intervals determined in the first direction, each density pattern having a lightness smaller than a determined density lightness threshold value and being parallel to a second direction which is a direction perpendicular to the first direction, and a light pattern having a lightness larger than the density lightness threshold value and larger than a determined light lightness threshold value being arranged between the density patterns; distance measurement point information which is information on distance measurement points included in a distance measurement target which is the reading target and includes a plurality of distance measurement points which are points for measuring a distance in the main scanning direction; and pixel position distance data used when measuring a distance between the distance measurement points, i.e., a distance between the distance measurement points, and the processor includes: a waveform data acquisition unit which acquires the waveform data generated by the line image reading unit from the line image reading unit and writes the waveform data into the storage unit; and a binarized image data conversion unit which reads the distance correction chart which is the reading target arranged so that the first direction is parallel to the main scanning direction by the line image reading unit, generates binarized chart waveform data obtained by binarizing, based on a determined intensity threshold value, the light receiving intensity of each pixel of the chart waveform data which is the waveform data written into the storage unit by the waveform data acquisition unit, into a dark value indicating that the light receiving intensity is lower than the intensity threshold value and a bright value indicating that the light receiving intensity is higher than the intensity threshold value.In the binarized chart waveform data, a dark pixel range which is a range of pixels sandwiched between two dark values adjacent to the bright value on the outside, wherein the number of pixels included in the dark pixel range matches the physical width of the self-dark pattern which is the corresponding dark pattern included in the dark pattern array information in consideration of the pixel size of the light receiving element, and the number of pixels between adjacent dark pixel ranges matches the physical pattern interval between the adjacent dark pattern which is the corresponding dark pattern and the self-dark pattern based on the difference between the physical positions of the adjacent dark pixel ranges and the self-dark pattern in consideration of the pixel size. A dark pixel range determination unit that determines the dark pixel range; For each of the dark pixel ranges, a representative pixel position represented as a pixel position in the waveform data is determined by the same determination method, a representative physical point corresponding to the representative pixel position is determined for the dark pattern corresponding to each of the dark pixel ranges, any one of the representative pixel positions is used as a reference pixel position, the representative physical point corresponding to the reference pixel position is used as a reference physical point, and a reference physical point distance which is the distance between the representative physical point corresponding to each of the representative pixel positions and the reference physical point is calculated based on the physical position and the physical width included in the dark pattern array information. For each of the representative pixel positions, a modified reference physical point distance obtained by subtracting a pixel position-dependent distance calculated from the pixel position, which is the value of the representative pixel position, from the reference physical point distance, or a stored reference physical point distance which is the reference physical point distance, is included in the pixel position distance data, and a pixel position distance data generation unit that generates and writes the pixel position distance data to the storage unit; A reference physical point distance calculation unit that calculates the reference physical point distance at the input pixel position with reference to the pixel position distance data, andA distance measurement device that operates as a distance measurement unit that reads a distance measurement target in which a plurality of the distance measurement points are arranged so as to be readable by the line image reading unit, generates the distance measurement waveform data that is the waveform data written in the storage unit by the waveform data acquisition unit, determines a distance measurement pixel position that is the pixel position corresponding to each distance measurement point based on the distance measurement point information for the distance measurement waveform data, calculates the reference physical point distance for each distance measurement pixel position by the reference physical point distance calculation unit, and measures the absolute value of the difference in the reference physical point distance of the calculated distance measurement pixel positions as the distance between the distance measurement points.

2. When the processor operates as the dark pixel range determination unit, it uses a matching determination condition which is a condition for determining that each of the dark pixel ranges matches the corresponding dark pattern. The matching determination condition includes a width pixel number condition which determines whether the number of pixels existing in each of the dark pixel ranges is included in a width pixel number range determined to include a value obtained by dividing the physical width of the corresponding dark pattern by the pixel size. The distance measurement device according to claim 1.

3. The matching determination condition includes an interval pixel number condition which determines whether the number of pixels between two adjacent dark pixel ranges is included in an interval pixel number range determined to include a value obtained by dividing the physical interval between the two dark patterns corresponding to the two adjacent dark pixel ranges by the pixel size, for each combination of two adjacent dark pixel ranges. The distance measurement device according to claim 2.

4. The matching determination condition includes an end pixel range condition which determines whether each of the dark pixel ranges is included in a determined number of end pixel ranges which are ranges of pixels determined at both ends of a plurality of the light receiving elements arranged in the main scanning direction. When one dark pixel range is included in each of the end pixel ranges, the end pixel range condition is satisfied, and when there is an end pixel range that does not include the dark pixel range, the end pixel range condition is not satisfied. The distance measurement device according to claim 3.

5. When the processor operates as the pixel position distance data generation unit, for each of the dark pixel ranges, the average of the pixel positions of the dark values at both ends of the dark pixel range is used as the representative pixel position. The distance measurement device according to any one of claims 1 to 4.

6. The memory unit further stores an invalid pixel position, which is the pixel position of a pixel that is not recognized as either the dark value or the bright value. The processor causes the line image reading unit to read a light pattern chart arranged as the object to be read, which has a uniform brightness greater than a determined brightness threshold, and generates waveform data. The invalid pixel position detection unit operates to write, into the memory unit as the invalid pixel position, the pixel position of a pixel whose light reception intensity in the light pattern waveform data, which is the waveform data written into the memory unit by the waveform data acquisition unit, is less than a determined second intensity threshold. When operating as the dark value pixel range determination unit, the processor determines the dark value pixel range without recognizing the pixel at the pixel position stored in the invalid pixel position as either the dark value or the bright value. The distance measurement device according to any one of claims 1 to 5.

7. The memory unit further stores a second invalid pixel position range, which is a range of pixel positions for which the distance between distance measurement points is not calculated. When operating as the distance measurement unit, the processor does not calculate the distance between distance measurement points for the distance measurement points corresponding to the distance measurement pixel positions included in the second invalid pixel position range. The distance measurement device according to any one of claims 1 to 6.

8. The memory unit further stores a calibration temperature, which is the temperature of the line image reading unit when reading the chart waveform data to generate the pixel position distance data, and a temperature correction coefficient. The processor operates as a temperature correction unit that processes the distance between distance measurement points corrected based on the difference between the temperature of the line image reading unit and the calibration temperature and the temperature correction coefficient so that it can be measured. The distance measurement device according to any one of claims 1 to 7.

9. When the correctable length, which is the length in the main scanning direction of the correctable range that is the range sandwiched by the dark patterns arranged at both ends in the main scanning direction in the distance correction chart, is shorter than the effective reading length, which is the length in the main scanning direction of the reading range that is the range where the light receiving elements of the line image reading unit are arranged, the chart arrangement position, which is the position in the main scanning direction where the distance correction chart is arranged, is set to a plurality of different positions such that the correctable ranges at adjacent chart arrangement positions have an overlapping portion, and the correctable sum range, which is the sum of the correctable ranges at each chart arrangement position, includes the reading range, or the length in the main scanning direction of the non-correction range, which is the range included in the reading range and not included in the correctable sum range, is determined to be equal to or less than the upper limit value of the non-correction range length; the processor operates as the binarized image data conversion unit, the dark value pixel range determination unit, and the pixel position distance data generation unit at each chart arrangement position, and generates the pixel position distance data including the reference physical point distance with respect to the common reference physical point for the pixel positions obtained at each chart arrangement position. The distance measurement device according to any one of claims 1 to 8.

10. When the processor causes each of the pixel position distance data belonging to the first pixel position distance data set and the second pixel position distance data set, which are the sets of pixel position distance data generated by operating as the pixel position distance data generation unit at the first chart arrangement position and the second chart arrangement position, which are two adjacent chart arrangement positions, to have the reference physical point distance with respect to the common reference physical point, when using the reference physical point distance of the first range second pixel position, which is the reference physical point distance from the reference physical point in the pixel position distance data belonging to the first pixel position distance data set for the first range second pixel position, which is the pixel position included in the pixel position distance data belonging to the second pixel position distance data set and having the pixel position included in the first pixel position definition range, which is the range of the pixel positions included in any of the pixel position distance data belonging to the first pixel position distance data set. The distance measurement device according to claim 9.

11. When the processor makes each of the pixel position distance data belonging to the first pixel position distance data set and the second pixel position distance data set, which are sets of the pixel position distance data generated by the pixel position distance data generation unit, have the reference physical point distance with respect to the common reference physical point at each of the first chart arrangement position and the second chart arrangement position, which are two adjacent chart arrangement positions, in a first pixel position definition range, which is a range of the pixel positions included in any of the pixel position distance data belonging to the first pixel position distance data set, a first boundary pixel position, which is the pixel position at the end on the side where each of the pixel position distance data belonging to the second pixel position distance data set exists; a first adjacent second pixel position, which is the pixel position that has the minimum adjacent pixel position difference, which is the minimum value of the difference between the first boundary pixel position and the pixel position, and is the same pixel position as the first boundary pixel position or a pixel position not included in the first pixel position definition range; and an adjacent pixel position gap distance obtained by multiplying the pixel size by the adjacent minimum pixel position difference are used. The distance measurement device according to claim 9.

12. The processor also operates as: an intensity reduction pixel detection unit that detects whether there is a pixel whose light reception intensity is smaller than a determined second intensity threshold value among the pixels of the light pattern waveform data, which is the waveform data generated by the line image reading unit reading a light pattern chart arranged as the object to be read and written in the storage unit by the waveform data acquisition unit, and that has a uniform lightness greater than a determined lightness threshold value; an intensity reduction pixel detection notification unit that notifies the user that there is a pixel whose light reception intensity is smaller than the second intensity threshold value when there is a pixel whose light reception intensity is smaller than the second intensity threshold value. The distance measurement device according to any one of claims 1 to 11.

13. The memory unit also stores an operation control flag that takes a value of operation stop or operable. When the processor operates as the intensity reduction pixel detection unit, if there are pixels whose received light intensity is smaller than the second intensity threshold, the operation control flag is set to operation stop. If there are no pixels whose received light intensity is smaller than the second intensity threshold, the operation control flag is set to operable. When the operation control flag is operable, the processor operates as the binarized image data conversion unit, the dark value pixel range determination unit, and the pixel position distance data generation unit. When the operation control flag is operation stop, the processor does not operate as the binarized image data conversion unit, the dark value pixel range determination unit, and the pixel position distance data generation unit. The distance measurement device according to claim 12.

14. When the processor operates as the reference physical point distance calculation unit, based on a pixel position distance graph that connects a straight line or a curve between two points corresponding to the pixel position distance data adjacent to the pixel position in the two-dimensional plane of the pixel position and the reference physical point distance, the reference physical point distance for the input pixel position is calculated. The distance measurement device according to any one of claims 1 to 13.

15. A method for generating pixel position distance data used when measuring the distances in the main scanning direction of a plurality of determined points of a reading target, using a line image reading unit that has a plurality of light receiving elements arranged in the main scanning direction, reads the reading target, converts the received light intensity, which is the light intensity received by each of the light receiving elements, into an electrical signal, and records it for each pixel associated with the arrangement position of each light receiving element in the main scanning direction to generate waveform data that is a line image, and a storage unit that stores the waveform data. A procedure for writing into the storage unit density pattern array information including a physical width that is the width of each of the density patterns in a distance correction chart having a length determined in the first direction, a physical position that is the position in the first direction, or information capable of calculating the physical position, where a plurality of density patterns having a width determined in the first direction and having a lightness smaller than a determined density lightness threshold value are arranged at intervals determined in the first direction, and light patterns having a lightness greater than a light lightness threshold value determined to be greater than the density lightness threshold value are arranged between the density patterns; a procedure for writing into the storage unit chart waveform data that is the waveform data generated by the line image reading unit reading the distance correction chart with the distance correction chart arranged so that the first direction is parallel to the main scanning direction; a procedure for converting into binarized chart waveform data binarized with a dark value indicating that the received light intensity is lower than a determined intensity threshold value and a light value indicating that the received light intensity is higher than the intensity threshold value based on the received light intensity of each pixel of the chart waveform data; and a dark pixel range determination procedure for determining a dark pixel range that is a range of pixels sandwiched between two dark values each having a light value adjacent thereto on the outside in the binarized chart waveform data, where the number of pixels included in the dark pixel range matches the physical width of a self-density pattern that is the corresponding density pattern included in the density pattern array information in consideration of the pixel size of the light receiving elements, and the number of pixels between adjacent dark pixel ranges matches the density pattern physical interval determined based on the difference between the physical position of the self-density pattern and the physical position of an adjacent density pattern that is the density pattern corresponding to the adjacent dark pixel range in consideration of the pixel size.For each of the dark value pixel ranges, determine a representative pixel position represented as a pixel position that is the position of a pixel in the waveform data by the same determination method. Determine a representative physical point corresponding to the representative pixel position in the dark pattern corresponding to each of the dark value pixel ranges. Use any one of the representative pixel positions as a reference pixel position, and use the representative physical point corresponding to the reference pixel position as a reference physical point. Calculate a reference physical point distance, which is the distance between the representative physical point corresponding to each representative pixel position and the reference physical point, based on the physical position and the physical width included in the dark pattern array information. For each representative pixel position, generate pixel position distance data including the pixel position, which is the value of the representative pixel position, and a corrected reference physical point distance obtained by subtracting a pixel position-dependent distance calculated from the pixel position from the reference physical point distance, or a stored reference physical point distance that is the reference physical point distance. A method for generating pixel position distance data comprising a step of writing the pixel position distance data into the storage unit.

16. A method for generating pixel position distance data using the line image reading unit having a transparent body between the object to be read and the light receiving element. A procedure of writing the light pattern waveform data, which is the waveform data generated by the line image reading unit reading a light pattern chart having a uniform lightness greater than a determined lightness threshold, into the storage unit with the light pattern chart arranged as the object to be read. An intensity reduction pixel detection procedure for determining whether there are pixels whose received light intensity in each pixel of the light pattern waveform data is smaller than a determined second intensity threshold. A cleaning procedure for the user to clean the surface of the transparent body when there are pixels whose received light intensity is smaller than the second intensity threshold. The method for generating pixel position distance data according to claim 15, wherein when there are no pixels whose received light intensity is smaller than the second intensity threshold, or after the cleaning procedure, the chart arrangement procedure is executed.

17. A procedure of writing, in the storage unit, light pattern waveform data, which is the waveform data generated by the line image reading unit reading a light pattern chart having a uniform lightness greater than a determined lightness threshold value, with the light pattern chart arranged as the object to be read; and a procedure, executed prior to the chart arrangement procedure, of checking whether the light reception intensity of each pixel of the light pattern waveform data is less than a determined second intensity threshold value and writing, in the storage unit, an invalid pixel position, which is the pixel position of a pixel having a light reception intensity less than the second intensity threshold value. In the dark value pixel range determination procedure, the dark value pixel range is determined without recognizing the pixels at the invalid pixel positions as either the dark values or the light values. A method for generating pixel position distance data according to claim 15.

18. A computer comprising a storage unit and a processor is connected to a line image reading unit that has a plurality of light receiving elements arranged in a main scanning direction, reads a reading target, converts a received light intensity, which is the intensity of light received by each of the light receiving elements, into an electrical signal, and generates waveform data that is a line image recorded for each pixel associated with the arrangement position of each of the light receiving elements in the main scanning direction. The storage unit stores density pattern arrangement information including a physical width, which is the width of each of the density patterns in a distance correction chart having a length determined in a first direction, and a physical position, which is the position in the first direction, or information capable of calculating the physical position, where the density patterns having a width smaller than a determined lightness threshold value are arranged at intervals determined in the first direction, and light patterns having a lightness greater than a lightness threshold value determined to be greater than the density threshold value are arranged between the density patterns, and the density pattern arrangement information is parallel to a second direction that is perpendicular to the first direction. A waveform data acquisition unit that acquires the waveform data generated by the line image reading unit from the line image reading unit and writes the waveform data into the storage unit. The line image reading unit reads the distance correction chart, which is the reading target arranged so that the first direction is parallel to the main scanning direction, generates the waveform data, and based on a determined intensity threshold value, converts the received light intensity of each pixel of the chart waveform data, which is the waveform data written into the storage unit by the waveform data acquisition unit, into binary chart waveform data that is binarized into a dark value indicating that the received light intensity is lower than the intensity threshold value and a bright value indicating that the received light intensity is higher than the intensity threshold value.In the binarized chart waveform data, a dark pixel range which is a range of pixels sandwiched between two dark values adjacent to the bright value on the outside, wherein the number of pixels included in the dark pixel range is the corresponding dark pattern included in the density pattern array information in consideration of the pixel size of the light receiving element. The physical width of the self-density pattern is matched, and the number of pixels between adjacent dark pixel ranges is the physical position of the adjacent density pattern, which is the density pattern corresponding to the adjacent dark pixel range, and the physical position of the self-density pattern in consideration of the pixel size. A dark pixel range determination unit that determines a dark pixel range that matches the density pattern physical interval determined based on the difference, and for each of the dark pixel ranges, a representative pixel position represented as a pixel position of a pixel in the waveform data by the same determination method. Determine, determine a representative physical point corresponding to the representative pixel position in the density pattern corresponding to each of the dark pixel ranges, use any one of the representative pixel positions as a reference pixel position, and use the representative physical point corresponding to the reference pixel position as a reference physical point. The reference physical point distance, which is the distance between the representative physical point corresponding to each representative pixel position and the reference physical point, is calculated based on the physical position and the physical width included in the density pattern array information, and for each representative pixel position, the pixel position which is the value of the representative pixel position and the pixel position-dependent distance calculated from the pixel position are subtracted from the reference physical point distance. A program for operating as a pixel position distance data generation unit that generates pixel position distance data including a corrected reference physical point distance obtained or a storage reference physical point distance that is the reference physical point distance and writes it into the storage unit.

19. A computer-readable recording medium recording the program according to claim 18.

Citation Information

Patent Citations

  • Distance measuring method

    JP1993172531A

  • Line sensor calibration value calculation device, target used for the device, object measuring system, line sensor calibration value calculation method, line sensor calibration value calculation program, and storage medium recording the program

    JP2007304653A

  • Correcting pattern for image devices

    JP2010160051A

  • Method for calibrating flat bed scanner

    JP2011151548A

  • Image reading device

    JP2016021601A