This application claims priority from Japanese Patent Application No. 2018-150191 filed on Aug. 9, 2018, the content of which is incorporated herein by reference in its entirety.
One or more aspects of the disclosure relate to a sewing machine.
A known sewing machine includes a projector. The projector disposed inside an arm includes a light transmission display such as a liquid crystal display (LCD), and a light source behind the LCD. The LCD displays thereon an image indicating an embroidery pattern shape, stitch start and end positions, and a stitch height position. When the light source turns on, the image displayed on the LCD is projected onto a fabric on a surface of a bed.
The position of a maximum area onto which a projector can project an image may vary among sewing machines because of an assembling error of a projector and individual differences among projectors. On the other hand, when an area onto which a projector projects an image is specified, as a guarantee area, by the specifications of a sewing machine or the like, the guarantee area needs to be contained in the maximum area commonly in each sewing machine.
According to an aspect of the disclosure, a sewing machine is configured to determine a target area containing a guarantee area while calibrating a projector. The projector is configured to project an image onto at least the guarantee area. An embroidery hoop for holding a workpiece may be moved relative to the target area.
According to an aspect of the disclosure, a sewing machine includes a bed, a projector configured to project an image toward the bed onto at least a guarantee area, a storage medium, and a controller. The controller is configured to control the projector to project the image toward the bed onto a maximum area. The controller is configured to determine, based on a position of the image projected onto the maximum area, first world coordinates representing, in a real space coordinate system, a rectangular area contained in the maximum area. The controller is configured to determine, based on the first world coordinates, second world coordinates representing, in the real space coordinate system, a target area containing at least the guarantee area. The controller is configured to store the second world coordinates in the storage medium.
The sewing machine according to the aspect of the disclosure determines the target area based on the second world coordinates stored in the storage medium.
Overview of Sewing Machine
An embodiment of the disclosure will be described with reference to the accompanying drawings. Referring to
As shown in
As shown in
As shown in
As shown in
As shown in
As shown in
The direction of the image light beams emitted from the projector 58 is slightly inclined rearward relative to a vertically downward direction. As a result, the maximum area M is a trapezoid having a front side and a rear side which are parallel to each other. The front side is less than the rear side.
As shown in
As shown in
When the sewing machine 1 executes embroidery sewing using the embroidery hoop 50, the moving unit 40 moves the embroidery hoop 50 in the X-axis and Y-axis directions while the needle bar drive mechanism 55 and the shuttle mechanism (not shown) are driven. This allows for the needle 6A attached to the needle bar 6 to sew embroidery patterns into the workpiece C held by the embroidery hoop 50.
Electrical Structure
Referring to
The CPU 81 performs overall control of the sewing machine 1. The CPU 81 performs various calculations and processing relating to sewing, in accordance with programs stored in the ROM 82. The ROM 82 includes a plurality of storage areas (not shown), including a program storage area. The program storage area stores therein various programs for operating the sewing machine 1. An example of the programs includes a program for executing main processing. The main processing will be described in detail below. The RAM 83 includes a storage area in which results of calculations performed by the CPU 81 is stored.
The flash memory 84 stores therein various parameters for the sewing machine 1 to perform various processing, coordinates (Qnx, Qny), a first target distance Hh, a second target distance Hw, first reference coordinates, second reference coordinates, and pattern data. The coordinates (Qnx, Qny), the first target distance Hh, the second target distance Hw, the first reference coordinates, and the second reference coordinates will be described below. The pattern data is used by the sewing machine 1 to sew available embroidery patterns. The flash memory 84 further stores therein correspondence between the type of embroidery hoop 50 and the sewable range R (refer to
The I/O interface 85 is connected to drive circuits 91-96, the touch screen 26, the start/stop switch 29, the image sensor 57C of the camera 57, the light source 58D of the projector 58, and a detector 35. The detector detects attachment of an embroidery hoop 50 to the moving unit 40 and outputs the detection result depending on the type of embroidery hoop 50. The detector detects the type of embroidery hoop 50 based on a combination of ON and OFF of a plurality of mechanical switches. The light source 58D of the projector 58 turns on by a control signal from the CPU 81. The image sensor 57C of the camera 57 outputs to the CPU 81, upon detecting light, signals indicating an image captured (hereinafter referred to as “a captured image”) in a capture area P.
The drive circuit 91 is connected to the machine motor 33. Based on a control signal from the CPU 81, the drive circuit 91 drives the machine motor 33. The driven machine motor 33 drives the needle bar drive mechanism 55 via the shaft 34, thereby moving the needle bar 6 up and down. The drive circuit 92 is connected to a feed amount adjustment motor 22. Based on a control signal from the CPU 81, the drive circuit 92 drives the feed amount adjustment motor 22. The driven feed amount adjustment motor 22 drives the feed dog 24 via the feed mechanism 23 of the sewing machine 1. The drive circuit 93 is connected to the LCD 15. Based on a control signal from the CPU 81, the drive circuit 93 drives the LCD 15 to display an image on the LCD 15. The drive circuit 94 is connected to the X-axis motor 44. The drive circuit 95 is connected to the Y-axis motor 45. Based on a control signal from the CPU 81, the drive circuits 94 and 95 drive the X-axis motor 44 and the Y-axis motor, respectively. The driven X-axis motor 44 and Y-axis motor 45 moves the embroidery hoop 50 attached to the moving unit 40, by a moving amount based on a control signal, in the left-right direction (X-axis direction) and in the front-rear direction (Y-axis direction). The drive circuit 96 is connected to the LCD panel 58C of the projector 58. Based on a control signal from the CPU 81, the drive circuit 96 drives the LCD panel 58C to display an image on the LCD panel 59.
Guarantee Area Q
The position of a maximum area M may vary among sewing machines 1 because of an assembling error of a projector 58 to a bed 11 and because of individual differences among projectors 58. To cope with this situation, as shown in
The position of the guarantee area Q is defined relative to the position of the needle hole 7A in the upper surface of the bed 11, and more specifically relative to the position of the needle drop position B on the upper surface of the bed 11. A rear left corner, a rear right corner, a front left corner, and a front right corner of the guarantee area Q are referred to as Q1, Q2, Q3, and Q4, respectively. The corners Q1 through Q4 are collectively referred to as Qn (n is any of 1, 2, 3, or 4). Coordinates representing the position of each corner Qn are determined relative to the needle drop position which is defined as an origin (0, 0, 0) in a three-dimensional coordinate system (hereinafter referred to as “a world coordinate system”). X-axis, Y-axis, and Z-axis directions in the world coordinate system respectively correspond to left-right, front-rear, and up-down directions of the sewing machine 1. Rightward, frontward, and upward directions correspond to positive directions in respective coordinate axes. Leftward, rearward, and downward directions correspond to negative directions in respective coordinate axes. The guarantee area Q is defined on an imaginary plane extending along the upper surface of the bed 11. Thus, Z-coordinates are always zero. Hereinafter, coordinates in the world coordinate system are shown by only an X-coordinate and a Y-coordinate while a Z-coordinate is omitted. For example, coordinates representing the position of each corner Qn are shown as (Qnx, Qny). The coordinates (Qnx, Qny) of the guarantee area Q are stored in the flash memory 84 as values unique to the sewing machine 1.
Overview of Main Processing
Referring to
First Main Processing
Referring to
As shown in
The CPU 81 executes camera calibration as described below (S13). The CPU 81 determines, based on the second captured image, coordinates representing the position of the pattern image in a coordinate system unique to the camera 57 (hereinafter referred to as “a camera coordinate system”). The CPU 81 determines, based on the relationship between the determined coordinates and the first reference coordinates, a first transformation matrix for transforming the camera coordinate system to the world coordinate system. The CPU 81 stores the determined first transformation matrix in the RAM 83. The first transformation matrix allows the capture area P of the camera 57 to be represented in the world coordinate system.
After completion of the camera calibration, the user removes the checker board from the bed 11 of the sewing machine 1. The CPU 81 drives the projector 58 and causes the LCD panel 58D to display thereon an image to be projected onto the maximum area M. Then, the CPU 81 turns on the light source 58D such that image light beams are emitted from the projector 58 and the image is projected onto the maximum area M (S15). A projection area of the projected image coincides with the maximum area M.
The CPU 81 executes projector calibration as described below (S17). The CPU 81 drives the camera 57 for image capture. The camera 57 captures the image projected onto the maximum area M in the capture area P. The camera 57 outputs to the CPU 81 signals indicating the captured image. The CPU 81 obtains the captured image (hereinafter referred to as “a first captured image”) based on the signals output from the camera 57. The obtained first captured image includes the projected image indicating the maximum area M. The CPU 81 retrieves and obtains the second reference coordinates stored in the flash memory 84. The second reference coordinates are reference coordinates representing the maximum area M in a coordinate system unique to the projector 58 (hereinafter referred to as “a projector coordinate system).
The CPU 81 determines, based on the first captured image, coordinates representing the position of the maximum area M in the camera coordinate system. The CPU 81 determines, based on the relationship between the determined coordinates and the obtained second reference coordinates, a second transformation matrix for transforming the projector coordinate system to the camera coordinate system. The CPU 81 determines, based on the first transformation matrix and the second transformation matrix, a third transformation matrix for transforming the projector coordinate system to the world coordinate system. The CPU 81 stores the determined third transformation matrix in the RAM 83. The third transformation matrix allows the maximum area M of the projector 58 to be represented in the world coordinate system.
The CPU 81 determines a rectangular area W from the maximum area M (S19) as described below to determine the target area G which is rectangular and contains the guarantee area Q. As shown in
Coordinates of the position of each corner Wn of the rectangular area W which are represented in the world coordinate system are determined based on the position of each corner Mn of the maximum area M, as described below. First, the CPU 81 determines, based on the first captured image obtained during the projector calibration (refer to S17), coordinates representing, in the camera coordinate system, the position of each corner Mn of the maximum area M indicated by the image projected by the projector 58. The CPU 81 applies the third transformation matrix to the determined coordinates to determine coordinates (Mnx, Mny) representing in the world coordinate system, the position of each corner Mn of the maximum area M.
Then, the CPU 81 determines, based on the determined coordinates (Mnx, Mny), coordinates (Wnx, Wny) representing, in the world coordinate system, the position of each corner Wn of the rectangular area W, as shown below.
As shown in
As shown in
In contrast, when the first distance H1 is greater than the first target distance Hh, the target area G falls within the rectangular area W in the Y-axis direction. When the CPU 81 determines that the first distance H1 is greater than the first target distance Hh (S23: YES), the processing goes to step S25. The CPU 81 calculates an X-axis distance of the rectangular area W as a second distance H2 (S25). More specifically, the CPU calculates the second distance H2 by subtracting X-coordinate W1x indicating the position of the corner W1 in the X-axis direction from the X-coordinate W2x indicating the position of the corner W2 in the X-axis direction (S25). The CPU 81 determines whether the calculated second distance H2 is greater than a second target distance Hw to determine whether the target area G falls within the rectangular area W in the X-axis direction. The second target distance Hw is a predetermined value indicating a minimum distance in the X-axis direction of the target area G, and is previously stored in the flash memory 84. When the first distance H2 is not greater than the target distance Hw, the target area G does not fall within the rectangular area W in the X-axis direction. A portion of the target area G is out of the rectangular area W in the X-axis direction. When the CPU 81 determines that the second distance H2 is not greater than the second target distance Hw (S27: NO), the processing goes to step S31. The CPU 81 controls the LCD 15 to display thereon a screen informing that it is impossible to set the target area G (S31). The CPU 81 ends the first main processing (refer to
In contrast, when the second distance H2 is greater than the second target distance Hw, the target area G falls within the rectangular area W in the X-axis direction and in the Y-axis direction. The CPU 81 determines whether the rectangular area W contains the guarantee area Q (S29). When at least one of the following conditions is not satisfied, the CPU 81 determines that the rectangular area W does not contain the guarantee area Q (S29: NO).
In this case, the processing goes to step S 31. The CPU 81 controls the LCD 15 to display thereon a screen notifying that it is impossible to set the target area G (S31). The CPU 81 ends the first main processing (refer to
In contrast, when all of the above conditions are satisfied, the CPU 81 determines that the rectangular area W contains the guarantee area Q (S29: YES). In this case, the processing goes to step S 41 (refer to
As shown in
In contrast, when the first world coordinate Q1x of the corner Q1 in the X-axis direction is less than W2x−Hw, the CPU 81 determines that the corner Q1 is not located within the range Si in the X-axis direction (S41: NO). In this case, the CPU 81 determines the second world coordinates G1x, G2x, G3x, and G4x in the X-axis direction, as shown below and in
The CPU 81 determines whether the corner Q3 of the guarantee area Q is located, in the Y-axis, within a range S2 (refer to
In contrast, when the first world coordinate Q3y of the corner Q3 in the Y-axis direction is greater than W1y+Hh, the CPU 81 determines that the corner Q3 is not located within the range S2 in the Y-axis direction (S47: NO). In this case, the CPU 81 determines the second world coordinates G1y, G2y, G3y, and G4y in the Y-axis direction, as shown below and in
For example, in a case shown in
A side W1-W2 (hereinafter referred to as “a first rectangular-area side W1-W2”) of the rectangular area W is adjacent to and offset in the negative Y-direction (upward) from the first guarantee-area side Q1-Q2 of the guarantee area Q. A side W3-W4 (hereinafter referred to as “a second rectangular-area side W3-W4”) of the rectangular area W is opposite to the first rectangular-area side W1-W2. A side G3-G4 (hereinafter referred to as “a third target-area side G3-G4”) between the corners G3 and G4 of the target area G is opposite to the first target-area side G1-G2. The third target-area side G3-G4 is located away by the first target distance Hh from the first rectangular-area side W1-W2 toward the second rectangular-area side W3-W4.
A side W2-W4 (hereinafter referred to as “a third rectangular-area side W2-W4”) of the rectangular area W is adjacent to and offset in the positive X-direction (rightward) from the second guarantee-area side Q2-Q4 of the guarantee area Q. A side W1-W3 (hereinafter referred to as “a fourth rectangular-area side W1-W3”) of the rectangular area W is opposite to the third rectangular-area side W2-W4. A side G1-G3 (hereinafter referred to as “a fourth target-area side G1-G3”) between the corners G1 and G3 of the target area G is opposite to the second target-area side G2-G4. The fourth target-area side G1-G3 is located away by the second target distance Hw from the third rectangular-area side W2-W4 toward the fourth rectangular-area side W1-W3.
For example, in a case shown in
A side W3-W4 (hereinafter referred to as “a first rectangular-area side W3-W4”) of the rectangular area W is adjacent to and offset in the positive Y-axis direction (downward) from the first guarantee-area side Q3-Q4 of the guarantee area Q. A side W1-W2 (hereinafter referred to as “a second rectangular-area side W1-W2”) of the rectangular area W is opposite to the first rectangular-area side W3-W4. A side G1-G2 (hereinafter referred to as “a third target-area side G1-G2”) between the corners G1 and G2 of the target area G is opposite to the first target-area side G3-G4. The third target-area side G1-G2 is located away by the first target distance Hh from the first rectangular-area side W3-W4 toward the second rectangular-area side W1-W2.
A side W1-W3 (hereinafter referred to as “a third rectangular-area side W1-W3”) of the rectangular area W is adjacent to and offset in the negative X-axis direction (leftward) from the second guarantee-area side Q1-Q3 of the guarantee area Q. A side W2-W4 (hereinafter referred to as “a fourth rectangular-area side W2-W4”) of the rectangular area W is opposite to the third rectangular-area side W1-W3. A side G2-G4 (hereinafter referred to as “a fourth target-area side G2-G4”) between the corners G2 and G4 of the target area G is opposite to the second target-area side G1-G3. The fourth target-area side G2-G4 is located away by the second target distance Hw from the third rectangular-area side W1-W3 toward the fourth rectangular-area side W2-W4.
The CPU 81 stores, in the flash memory 84 (S53), the second world coordinates (Gnx, Gny) determined in the processing in steps S43, S45, S49, and S51. The CPU 81 ends the first main processing.
Second Main Processing
Referring to
As shown in
The CPU 81 determines a sewable range R (refer to
Operation and Effects
The sewing machine 1 determines the first world coordinates (Wnx, Wny) representing the rectangular area W in the world coordinate system (S19). The sewing machine 1 further determines, based on the determined first world coordinates (Wnx, Wny), the second world coordinates (Gnx, Gny) representing the target area G in the world coordinate system (S41-S51), and stores the determined second world coordinates (Gnx, Gny) in the flash memory (S53). The sewing machine 1 is allowed to determine the target area G based on the second world coordinates (Gnx, Gny) stored in the flash memory 84.
The sewing machine 1 is operable with the moving unit 40 attached thereto. The moving unit 20 moves the embroidery hoop 50 holding a workpiece C. The sewing machine 1 drives the moving unit 40 based on the second world coordinates (Gnx, Gny) stored in step S53, thereby moving the embroidery hoop 50 holding the workpiece C to a position where the center of the target area G coincides with the center of a sewable range R in the embroidery hoop 50 (S65). The target area G contains the guarantee area Q onto which the projector 58 projects an image. The center of the sewable range R corresponds to a position at which the sewing machine 1 starts sewing an embroidery pattern on the workpiece C held by the embroidery hoop. When the workpiece C is moved as described above in the sewing machine 1, the projector 58 is allowed to project an image showing an embroidery pattern onto the workpiece C at a position where the embroidery pattern is actually to be sewn.
The guarantee area Q contains at least a portion of the needle plate 7 on the bed 11. In this case, in the sewing machine 1, the projector 58 is allowed to project an image onto an area containing at least the portion of the needle plate 7. The guarantee area Q contains at least the needle hole 7 formed in the bed 11. In this case, in the sewing machine 1, the projector 58 is allowed to project an image onto an area containing at least the needle hole 7A.
In order to determine the third transformation matrix for transforming the projector coordinate system to the world coordinate system, the sewing machine 1 is required to determine, in the world coordinate system, the position of an area (the maximum area M or the rectangular area W) onto which the projector 58 projects an image. As an example for this purpose, providing a sensor on the bed 11 in the sewing machine 1 is conceivable to detect the positions of corners of the maximum area M designated by a user. In contrast, in the above-described embodiment, the sewing machine 1 includes the camera 57 configured to capture an image in the capture area P which contains the maximum area M. The camera 57 captures an image of the checker board placed at the predetermined position in the capture area P (S11). During the camera calibration (S13), the sewing machine 1 determines the first transformation matrix for transforming the camera coordinate system to the world coordinate system. The first transformation matrix transforms the capture area P into the world coordinate system. During the subsequent projector calibration (S17), the CPU 81 determines, using the determined first transformation matrix, the third transformation matrix for transforming the projector coordinate system to the world coordinate system. The sewing machine 1 determines the third transformation matrix without the use of a sensor nor the intervention of a user. The sewing machine 1 determines, using the determined third transformation matrix, the second world coordinates (Gnx, Gny) of the target area G.
During the projector calibration (S17), the sewing machine 1 determines the coordinates representing the position of the maximum area M in the camera coordinate system, based on the first captured image captured by the camera 57. The sewing machine 1 determines, based on the determined coordinates, the second transformation matrix for transforming the projector coordinate system to the camera coordinate system. The sewing machine 1 further determines, based on the first transformation matrix and the second transformation matrix, the third transformation matrix for transforming the projector coordinate system to the world coordinate system. Thus, the sewing machine 1 determines, using the determined third transformation matrix, the second world coordinates (Gnx, Gny) of the target area G.
The position of the guarantee area Q is determined relative to the needle drop position B on the bed 11. The sewing machine 1 determines the guarantee area Q accurately by obtaining the needle drop position.
The sewing machine 1 determines the target area G based on the positions of the sides of the rectangular area W and the guarantee area Q (S41-S51). By doing so, the sewing machine 1 properly determines the guarantee area G which is contained in the rectangular area W and contains the guarantee area Q.
Upon determining that the target area G is not contained in the rectangular area W (S23: NO, S27: NO), the sewing machine 1 displays on the LCD 15 a screen notifying the user to that effect (S31).
Modifications
While the disclosure has been described with reference to the specific embodiment, various changes and modifications may be applied therein without departing from the spirit and scope of the disclosure. In the above-described embodiment, the world coordinate system is used as an example of a real space coordinate system. A real space coordinate system is a coordinate system indicating positions in a real space. However, any coordinate system may be used as long as it determines coordinates representing at least two-dimensional positions in X-axis and Y-axis directions in a real space. Instead of the Cartesian coordinate system in the above-described embodiment, a polar coordinate system may be used as a coordinate system indicating two-dimensional positions.
The CPU 81 determines, as the rectangular area W, the maximum rectangular area contained in the maximum area M. However, the rectangular area W may not be the maximum rectangular area contained in the maximum area M. The area determined in step S19 may be a rectangular area contained in the maximum area M, other than the maximum rectangular area. The projector 58 is not limited to the LCD projector. A cathode ray tube (CRT) projector and a digital light processing (DLP) projector may be used. A storage medium storing the second world coordinates (Gnx, Gny) is not limited to the flash memory 84. The second world coordinates may be stored in a storage medium such as a USB memory.
The guarantee area Q may be defined as an area not containing the needle plate 7 on the bed 11. The guarantee area Q may be defined as an area not containing the needle hole 7A in the needle plate 7.
The CPU 81 may not execute camera calibration (S13) or projector calibration (S17). In this case, a sensor such as a touch screen may be provided on the bed 11 of the sewing machine 1. The user may designate, via the sensor, the positions of the corners of the maximum area M projected by the projector 58. The CPU 81 may directly determine the second world coordinates (Gnx, Gny) of the rectangular area W, based on the designated positions of the corners of the maximum area M. In this case, the sewing machine 1 may not include the camera 57.
The CPU 81 may determine the position of the needle drop position B from an image captured by the camera 57. The CPU 81 may determine the guarantee area Q relative to the position of the determined needle drop position B. The guarantee area Q may be determined relative to a reference position (e.g. the position of a mark previously provided on the needle plate 7), instead of the needle drop position B.
In the above-described embodiment, the second world coordinates (Gnx, Gny) stored in the flash memory 84 during the first main processing are referred to in the step for moving the workpiece C during the second main processing. The second world coordinates (Gnx, Gny) stored in the flash memory 84 may be referred to in other processing. For example, the CPU 81 may control the projector 58 to project an image including selection buttons. The CPU 81 may control the camera 57 to capture the position of a finger of the user pointing to a desired selection button. The CPU 81 may determine, in the world coordinate system, the coordinates representing the position of the finger included in the captured image, based on the second world coordinates (Gnx, Gny). The CPU 81 may determine the selection button located at the determined coordinates and execute processing accordingly.
A method for determining the target area G from the rectangular area W is not limited to the above-described method. For example, the CPU 81 may determine, as the target area G, an area formed by moving each side of the rectangular area W inward by a predetermined distance at a time.
A method of notifying that the target area G is not contained in the rectangular area W (S23: NO, S27: NO) is not limited to the above-described method. For example, the CPU 81 may notify by outputting an alarm from a speaker provided in the sewing machine 1. Upon determining that the target area G is not contained in the rectangular area W (S23: NO, S27: NO), the CPU81 may end the first main processing without notifying the user.
There is a case where the projector 58 is specified by the product specifications or by a fixing method such that at least the target area G is contained in the rectangular area W. In this case, the CPU 81 may not determine whether the target area G is contained in the rectangular area W (S23, S27).
Others
The elements in the above-described embodiment correspond to elements of a sewing machine according to an aspect of the disclosure, as below. The projector 58 is an example of a projector. The CPU 81 executing step S15 is an example of a controller controlling a projector. The CPU 81 executing step S19 is an example of the controller determining first world coordinates. The CPU 81 executing steps S41-S51 is an example of the controller determining second world coordinates. The flash memory 84 is an example of a storage medium. The CPU 81 executing step S53 is an example of the controller storing the second world coordinates. The camera 57 is an example of a capture unit. The third transformation matrix is an example of a first parameter. The CPU 81 executing step S17 is an example of the controller determining the first parameter. The first transformation matrix is an example of a second parameter. The CPU 81 executing step S13 is an example of the controller determining the second parameter. The CPU 81 executing steps S23 and S27 is an example of the controller determining. The CPU 81 executing step S31 is an example of the controller notifying. The CPU 81 executing step S65 is an example of the controller controlling a moving unit.
Number | Date | Country | Kind |
---|---|---|---|
2018-150191 | Aug 2018 | JP | national |