A method and system for ampoule handling for an automatic dispensing machine
By setting the motion coordinate system of the robotic arm, calibrating the reference coordinates, and calculating the compensation value, the problem that the ampoule handling method could not adapt to different sizes was solved, realizing efficient and accurate bottle cutting and knocking operations, and improving the processing capacity of the automatic dispensing machine.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- 美蓝(杭州)医药科技有限公司
- Filing Date
- 2026-03-30
- Publication Date
- 2026-06-23
AI Technical Summary
In the existing technology, the ampoule processing method is inefficient and cannot adapt to ampoules of different sizes, resulting in inaccurate cutting and tapping positions, which affects the efficiency and quality of drug dispensing.
By setting the XYZ three-dimensional spatial coordinate system for the robotic arm's movement, calibrating the reference coordinates, calculating the compensation value and correcting the positioning coordinates, and combining the fixed robotic arm posture parameters, the robotic arm is controlled to perform bottle cutting and bottle knocking operations.
It enables precise handling of ampoules of different sizes, improving medication dispensing efficiency and quality, and ensuring patient medication safety.
Smart Images

Figure CN122254428A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of automated medical dispensing, and in particular to a method and system for handling ampoules in an automated dispensing machine. Background Technology
[0002] In the medical field, the development of automated dispensing machines has greatly improved the efficiency and accuracy of medication dispensing, reducing errors that may occur with manual dispensing, and is of great significance for ensuring patient medication safety. As the medical industry continues to demand higher levels of automation in medication dispensing, the various functions of automated dispensing machines are constantly being improved and optimized. Ampoules, as a commonly used form of drug packaging, are a key component in the processing of ampoules in automated dispensing machines, significantly impacting efficiency and quality. The level of automation in ampoule handling directly affects the smoothness and accuracy of the entire dispensing process, thus influencing patient treatment outcomes. Currently, the handling of ampoules in automated dispensing machines typically employs manual assistance or simple mechanical positioning methods. Manual assistance involves operators placing the ampoules into the working positions of the cutting and tapping mechanisms. While this method can complete ampoule handling to some extent, it is inefficient and easily affected by the operator's skill level and work status, leading to inconsistent processing results. Simple mechanical positioning methods handle ampoules by setting pre-defined fixed positions. This method is poorly adaptable to ampoules of different sizes, unable to accurately adjust to the actual dimensions of the ampoule, and prone to problems such as inaccurate cutting and misaligned tapping. The drawback of existing technologies is that neither manual assistance nor simple mechanical positioning methods can adequately meet the processing needs of ampoules of different sizes. Manual assistance is inefficient and prone to errors, while simple mechanical positioning methods cannot flexibly adjust to the actual dimensions of the ampoule, leading to inaccurate cutting and tapping when handling ampoules of different sizes, affecting the efficiency and quality of medication dispensing. Summary of the Invention
[0003] This invention solves the problem of inaccurate positioning of ampoules and bottles, which affects the efficiency and quality of drug dispensing. It proposes a method and system for ampoule handling in automatic drug dispensing machines. The main approach is to set coordinates, calculate compensation values, and control the operation of the robotic arm. This achieves the effect of adapting to the handling of ampoules of different sizes and improving the efficiency and quality of drug dispensing.
[0004] To achieve the above objectives, the following technical solution is proposed: A method for handling ampoules in an automated dispensing machine, applicable to a robotic arm's front-end gripper grasping ampoules and transferring them to a bottle-cutting mechanism and a bottle-striking mechanism, includes the following steps: S1, Set the XYZ three-dimensional coordinate system for the robotic arm movement. The front gripper picks up the smallest size ampoule and moves it to the working position of the bottle cutting mechanism. The coordinates of the center position of the front gripper at this time are calibrated as the bottle cutting reference coordinates (X0, Y0, Z0). The front gripper picks up the smallest size ampoule and moves it to the working position of the bottle knocking mechanism. The coordinates of the center position of the front gripper at this time are calibrated as the bottle knocking reference coordinates (X1, Y1, Z1). S2, based on the set segment interval of the bottle diameter, and set the slope and intercept corresponding to each segment interval, calculate the target value according to the linear function; S3, obtain the ampoule's body diameter, neck diameter D, and total height H through visual recognition; S4, Calculate the compensation value used to correct the actual position of the robotic arm: Compensation value = (Target value - Bottle diameter / 2) - Calibration bias term; S5, based on the compensation value and the bottleneck diameter D, correct the actual bottle cutting coordinate point of the front gripper center position; S6, based on the compensation value and the total height H of the bottle, correct the actual bottle-knocking coordinate point of the center position of the front gripper; S7 inputs the preset robotic arm posture parameters and the calculated actual bottle cutting and knocking coordinates into the robotic arm control system, controlling the robotic arm to first move to the bottle cutting mechanism to perform the bottle cutting operation and then move to the bottle knocking mechanism to perform the bottle knocking operation.
[0005] This invention, by constructing a robotic arm motion coordinate system, calibrating reference coordinates, calculating compensation values based on ampoule dimensions and correcting the positioning coordinates, and combining fixed robotic arm posture parameters, can accurately control the robotic arm to perform cutting and tapping operations on ampoules of different sizes. Compared with existing technologies, it avoids the problems of low efficiency and high error rates associated with manual assistance, as well as the shortcomings of simple mechanical positioning methods that cannot adapt to ampoules of different sizes, thereby improving the efficiency and quality of medication dispensing and ensuring patient medication safety.
[0006] Preferably, the process of constructing the XYZ three-dimensional spatial coordinate system for the robotic arm motion is as follows: a reference origin is set, the horizontal forward direction of the robotic arm is taken as the X-axis, the horizontal rightward lateral movement direction of the robotic arm is taken as the Y-axis, and the vertical upward movement direction of the robotic arm is taken as the Z-axis.
[0007] Preferably, step S2 specifically includes the following steps: Based on the set diameter of the bottle, the segments are divided into 3 sections: The first interval is (11, 15.77] mm. The slope is set to 0.1333 and the intercept to 6.1467. At this time, the target value is 0.1333 × bottle diameter + 6.1467. The second interval is (15.77, 18.3] mm. The slope is set to 0.085 and the intercept to 6.73. At this time, the target value is 0.085 × bottle diameter + 6.73. The third interval is (18.3, 26] mm. The slope is set to 0.09 and the intercept to 6.5. At this time, the target value is 0.09 × bottle diameter + 6.5.
[0008] This application calculates the target value segmented according to the bottle diameter (mm) (units are in the same coordinate system, assumed to be mm). Because the gripper holds bottles of different diameters at different positions, it is necessary to calculate the offset based on the bottle diameter.
[0009] Preferably, S5 specifically includes: calculating the actual bottle-cutting coordinates (X2, Y2, Z2) of the center position of the front gripper, wherein: X2 = X0 + bottleneck diameter D - compensation value; Y2 = Y0; Z2 = Z0 - H + ΔZ1, where ΔZ1 is the gripper height offset value.
[0010] Preferably, S5 specifically includes: calculating the actual bottle-knocking coordinates (X3, Y3, Z3) of the center position of the front gripper, wherein: X3 = X1 - compensation value; Y3 = Y1; Z3 = Z1 - (bottle height - ΔZ2), where ΔZ2 is the gripper height offset value.
[0011] Since the front-end gripper passes through the bottle-cutting mechanism and the bottle-knocking mechanism in sequence after grasping the ampoule, the gripping position hardly changes, therefore ΔZ1=ΔZ2.
[0012] Preferably, step S4 further includes the following step before calculating the compensation value: Determine if the bottle diameter is within the segmented range. If so, calculate the compensation value; otherwise, the robotic arm directly throws out the ampoule, and the feedback information is that the diameter is not within the valid segmented range.
[0013] Preferably, the robotic arm's pose parameters include the robotic arm's roll angle W, pitch angle P, and yaw angle R in space.
[0014] The bottle cutting position parameters are a fixed combination: W=179.4, P=-90.0, R=0. This combination ensures that the cutting mechanism is aligned with the bottle cutting position in a preset posture.
[0015] The bottle-tapping posture parameters adopt a fixed combination: W=179.8, P=-90.0, R=0. This posture ensures that the bottle-tapping mechanism acts on the target position of the bottle at a preset angle, ensuring the consistency of the bottle-tapping position and direction.
[0016] An ampoule handling system for an automatic dispensing machine, applicable to the aforementioned ampoule handling method for an automatic dispensing machine, includes: a vision recognition module for acquiring the ampoule's body diameter, neck diameter D, and total height H; a cutting mechanism with a horizontal cutting blade for cutting the ampoule's neck; a striking mechanism with an electrically driven turntable, the turntable having an eccentrically positioned striking post for striking the cut ampoule; a robotic arm control system with a data storage module, a data processing module, and an execution control module, the data processing module having a program for calculating the actual positioning coordinates of the cutting and striking operations, the data storage module storing all preset calculation parameters and results, and the execution control module controlling the front-end gripper to perform the capping operation based on the actual positioning coordinates of the cutting and striking operations; the front-end gripper is used to hold the ampoule.
[0017] Preferably, the front-end gripper includes a first gripper and a second gripper arranged symmetrically on the left and right, and a limiting member disposed between the first gripper and the second gripper. The first gripper and the second gripper are driven by a pneumatic cylinder or an electric cylinder and move towards or away from the limiting member at the same time.
[0018] The ampoule is positioned between the first clamp, the second clamp, and the limiting member.
[0019] The beneficial effects of this invention are as follows: By constructing a robotic arm motion coordinate system, calibrating reference coordinates, calculating compensation values based on ampoule dimensions and correcting the positioning coordinates, and combining fixed robotic arm posture parameters, this invention can accurately control the robotic arm to perform bottle cutting and tapping operations on ampoules of different sizes. Compared with existing technologies, it avoids the problems of low efficiency and high error rates associated with manual assistance, as well as the shortcomings of simple mechanical positioning methods that cannot adapt to ampoules of different sizes, thereby improving the efficiency and quality of medication dispensing and ensuring patient medication safety. Attached Figure Description
[0020] Figure 1 This is a flowchart of the method of the present invention.
[0021] Figure 2 This is a schematic diagram of the bottle-cutting posture along the XY axis of the present invention.
[0022] Figure 3 This is a schematic diagram of the bottle-cutting posture along the XZ axis of the present invention.
[0023] Figure 4 This is a schematic diagram of the bottle-cutting posture along the XY axis of the present invention.
[0024] Figure 5 This is a schematic diagram of the bottle-cutting posture along the XZ axis of the present invention.
[0025] The components include: 1. robotic arm; 2. ampoule; 3. first clamping member; 4. second clamping member; 5. limiting member; 6. bottle cutting mechanism; 7. bottle knocking mechanism; 8. horizontal cutting blade; 9. turntable; 10. bottle knocking column. Detailed Implementation
[0026] The technical solutions in the embodiments of the present invention will be further described in detail below with reference to the accompanying drawings. The described embodiments are only possible technical implementations of the present invention, but are not limited thereto. Other embodiments obtained by those skilled in the art in conjunction with the embodiments of the present invention without creative effort are also within the protection scope of the present invention.
[0027] This application mainly adopts a scheme of setting coordinates, calculating compensation values and controlling the operation of a robotic arm, which achieves the effect of adapting to the processing of ampoules of different sizes and improving the efficiency and quality of drug dispensing. The following is a further detailed description of this application. Example
[0028] This application provides an embodiment of an ampoule processing method for an automatic dispensing machine, referencing... Figure 1 The process includes setting the robotic arm's motion coordinate system, calibrating the reference coordinates, calculating the target value, obtaining the ampoule dimensions, calculating the compensation value, correcting the positioning coordinates, and controlling the robotic arm's operation. Through the coordination of these steps, the robotic arm's working position can be flexibly adjusted according to the actual size of the ampoule, thus adapting to the processing needs of ampoules of different sizes and improving the efficiency and quality of medication dispensing. Specifically, by setting the reference coordinates and calculating the compensation value, the actual positioning of ampoules of different sizes during cutting and tapping can be accurately determined, avoiding inaccurate cutting and tapping positions caused by differences in ampoule sizes.
[0029] Specifically, in the step of setting up the XYZ three-dimensional coordinate system for the robotic arm's movement, a reference origin needs to be established, with the horizontal forward direction of the robotic arm as the X-axis, the horizontal rightward movement direction as the Y-axis, and the vertical upward movement direction as the Z-axis. This reference origin can be the initial position of the robotic arm or a fixed point within the automated dispensing machine. In practical applications, other suitable methods can be chosen to construct the coordinate system based on the specific equipment layout and usage requirements, such as using a feature point of the bottle-cutting or bottle-striking mechanism as the reference origin.
[0030] Next, the reference coordinates are calibrated. The front gripper picks up the smallest size ampoule and moves it to the working position of the bottle-cutting mechanism. The coordinates of the center position of the front gripper at this point are calibrated as the bottle-cutting reference coordinates (X0, Y0, Z0). The front gripper then picks up the smallest size ampoule and moves it to the working position of the bottle-striking mechanism. The coordinates of the center position of the front gripper at this point are calibrated as the bottle-striking reference coordinates (X1, Y1, Z1). During the calibration process, it is essential to ensure that the front gripper accurately picks up the ampoule and that the ampoule is in the correct working position to guarantee the accuracy of the reference coordinates.
[0031] Then, based on the set bottle diameter, the system is divided into segments, and the slope and intercept of each segment are set. The target value is then calculated using a linear function. Specifically, the target value is divided into three intervals based on the bottle diameter: the first interval is (11, 15.77] mm, with a slope of 0.1333 and an intercept of 6.1467, where the target value is 0.1333 × bottle diameter + 6.1467; the second interval is (15.77, 18.3] mm, with a slope of 0.085 and an intercept of 6.73, where the target value is 0.085 × bottle diameter + 6.73; and the third interval is (18.3, 26] mm, with a slope of 0.09 and an intercept of 6.5, where the target value is 0.09 × bottle diameter + 6.5. The reason for calculating the target value segmented by bottle diameter is that the gripper positions differently when holding bottles of different diameters, necessitating offset calculations based on the bottle diameter. In practical applications, more intervals can be added based on more experimental data and actual needs to improve calculation accuracy.
[0032] The ampoule's body diameter, neck diameter D, and total height H are obtained through visual recognition. Visual recognition can utilize devices such as cameras and image processing technology to accurately measure the ampoule's dimensions. After obtaining the dimensions, it's necessary to determine if the body diameter falls within a defined segment range. If so, a compensation value is calculated; otherwise, the robotic arm directly ejects the ampoule, with feedback indicating that the diameter is outside the valid segment range.
[0033] The compensation value is calculated as follows: Compensation value = (Target value - Bottle diameter / 2) - Calibration bias term. The calibration bias term here is a fixed value determined during system debugging to correct for potential errors.
[0034] Based on the compensation value and the bottleneck diameter D, correct the actual bottle-cutting coordinates of the front gripper center position, and calculate the actual bottle-cutting coordinates (X2, Y2, Z2) of the front gripper center position. (Refer to...) Figure 2Where: X2 = X0 + neck diameter D - compensation value; Y2 = Y0; Z2 = Z0 - H + ΔZ1, where ΔZ1 is the gripper height offset value. The compensation value is used to correct the X-direction positioning deviation caused by the difference in bottle diameter, and the neck diameter D is used to adapt the radial correspondence between the neck and the cutting position. The bottle height H is used to offset the influence of different bottle heights on the Z-direction positioning, and the gripper height offset ΔZ is used to correct the vertical deviation caused by the size of the gripper itself.
[0035] Based on the compensation value and the total bottle height H, correct the actual bottle-striking coordinates of the center position of the front gripper. Calculate the actual bottle-striking coordinates (X3, Y3, Z3) of the center position of the front gripper. (Refer to...) Figure 4 Where: X3 = X1 - compensation value; Y3 = Y1; Z3 = Z1 - (bottle height - ΔZ2), where ΔZ2 is the gripper height offset value. Since the front gripper passes through the bottle-cutting mechanism and the bottle-striking mechanism sequentially after grasping the ampoule, the gripping position hardly changes; therefore, ΔZ1 = ΔZ2. The compensation value is used to specifically correct the radial positioning deviation of the bottle-striking operation, adapting the bottle-striking tool to the action position of the bottle. (Bottle height - ΔZ2) reflects the actual effective height of the bottle (the main body height of the bottle after deducting the gripper offset). By subtracting this value from the reference value, vertical positioning correction for bottles of different heights is achieved.
[0036] Finally, the preset robotic arm pose parameters and the calculated actual bottle cutting and knocking coordinates are input into the robotic arm control system. The system controls the robotic arm to first move to the bottle cutting mechanism to perform the cutting operation, and then to the bottle knocking mechanism to perform the knocking operation. The robotic arm pose parameters include the robotic arm's roll angle W, pitch angle P, and yaw angle R in space. The bottle cutting pose parameters use a fixed combination: W=179.4, P=-90.0, R=0. This combination ensures that the cutting mechanism aligns with the bottle cutting position in a preset posture. The bottle knocking pose parameters use a fixed combination: W=179.8, P=-90.0, R=0. This posture ensures that the knocking mechanism acts on the target position on the bottle at a preset angle, guaranteeing the consistency of the knocking position and direction.
[0037] The implementation principle of this embodiment is as follows: By constructing a robotic arm motion coordinate system, calibrating the reference coordinates, calculating compensation values based on the ampoule size and correcting the positioning coordinates, and combining fixed robotic arm posture parameters, this embodiment can accurately control the robotic arm to perform bottle cutting and tapping operations on ampoules of different sizes. Compared with existing technologies, this avoids the problems of low efficiency and high error rate of manual assistance methods, as well as the shortcomings of simple mechanical positioning methods that cannot adapt to ampoules of different sizes, thus improving the efficiency and quality of medication dispensing and ensuring patient medication safety. Example
[0038] The difference between this embodiment and the previous embodiment is that, when setting the coordinate system for the robotic arm's motion, it is also possible to use the center of the automatic dispensing machine as the reference origin, with the horizontal rightward direction as the positive X-axis, the horizontal forward direction as the positive Y-axis, and the vertical upward direction as the positive Z-axis. This coordinate system setting method may be more convenient and intuitive in certain equipment layouts, and can better coordinate with other components.
[0039] The implementation principle of this embodiment is as follows: by changing the setting method of the coordinate system, accurate control of the movement of the robotic arm can also be achieved, and it may have better adaptability in specific equipment layouts, improving the flexibility and operability of the system, and further improving the processing effect of ampoules of different sizes. Example
[0040] This application provides an ampoule handling system for an automated dispensing machine, comprising a vision recognition module, a cutting mechanism, a tapping mechanism, a robotic arm control system, and a front-end gripper. These modules and mechanisms work together to accurately acquire the size information of the ampoules and control the robotic arm 1 to cut and tap the ampoules based on this information, thereby achieving efficient processing of ampoules of different sizes. Specifically, the vision recognition module provides accurate ampoule size data, the cutting and tapping mechanisms have corresponding functions, the robotic arm control system can perform calculations and control based on this data, and the front-end gripper can stably hold the ampoules.
[0041] Specifically, the visual recognition module employs a high-precision camera and advanced image processing algorithms to acquire the ampoule's body diameter, neck diameter D, and total height H. The camera can be installed in a suitable position on the automated dispensing machine to ensure clear imaging of the ampoule. In practical applications, multiple cameras can also be used to capture images from different angles to improve the accuracy of dimensional measurements.
[0042] refer to Figure 3 The bottle-cutting mechanism 6 is equipped with a horizontal cutting blade 8, which is made of high-strength, sharp material and is used to cut the neck of the ampoule 2. The blade can be driven by a motor to cut at a constant speed to ensure the quality and stability of the cut. In some cases, a hydraulically driven blade can also be used to provide greater cutting force.
[0043] refer to Figure 5 The bottle-tapping mechanism 7 is equipped with an electrically driven turntable 9, on which a bottle-tapping post 10 is eccentrically mounted. The electrically driven turntable 9 can precisely control the rotation speed and direction. The bottle-tapping post 10 is made of wear-resistant material and is used to tap the ampoule 2 after it has been cut. By eccentrically setting the bottle-tapping post 10, the force and angle of the tapping can be made more appropriate, thus improving the success rate of tapping.
[0044] The robotic arm control system includes a data storage module, a data processing module, and an execution control module. The data storage module uses a large-capacity memory to store all preset calculation parameters and results. The data processing module has a program for calculating the actual coordinates of bottle cutting and knocking, which can accurately calculate the actual coordinates based on the size information provided by the vision recognition module and preset parameters. The execution control module controls the front-end gripper to perform the cap opening operation based on the actual coordinates of bottle cutting and knocking. It can communicate with the robotic arm in real time to ensure the robotic arm executes the operation accurately.
[0045] refer to Figure 4 The front-end gripper includes a first gripper 3 and a second gripper 4 symmetrically arranged on both sides, and a limiting member 5 positioned between the first gripper 3 and the second gripper 4. The first gripper 3 and the second gripper 4 are driven by either a pneumatic cylinder or an electric cylinder, moving simultaneously towards or away from the limiting member 5. The ampoule 2 is positioned between the first gripper 3, the second gripper 4, and the limiting member 5. Pneumatic cylinder drive features fast response and high force, while electric cylinder drive offers high control precision. In practical applications, the appropriate drive method can be selected according to specific needs.
[0046] The implementation principle of this embodiment is as follows: Through the coordinated work of various modules and mechanisms, this embodiment can accurately obtain the size information of the ampoule, and precisely control the robotic arm to cut and tap the ampoule based on this information. Compared with the prior art, it can better adapt to the processing needs of ampoules of different sizes, improve the automation and efficiency of medication dispensing, reduce errors that may be caused by manual intervention, and ensure the quality of medication dispensing and the safety of patients' medication.
[0047] The above are all preferred embodiments of this application, and are not intended to limit the scope of protection of this application. Therefore, all equivalent changes made in accordance with the structure, shape and principle of this application should be covered within the scope of protection of this application.
Claims
1. An ampoule handling method for an automatic dispensing machine, suitable for a front end gripper of a robot to pick up an ampoule to a bottle cutting mechanism and a bottle knocking mechanism, characterized in that, Includes the following steps: S1, Set the XYZ three-dimensional coordinate system for the robotic arm movement. The front gripper picks up the smallest size ampoule and moves it to the working position of the bottle cutting mechanism. The coordinates of the center position of the front gripper at this time are calibrated as the bottle cutting reference coordinates (X0, Y0, Z0). The front gripper picks up the smallest size ampoule and moves it to the working position of the bottle knocking mechanism. The coordinates of the center position of the front gripper at this time are calibrated as the bottle knocking reference coordinates (X1, Y1, Z1). S2, based on the set segment interval of the bottle diameter, and set the slope and intercept corresponding to each segment interval, calculate the target value according to the linear function; S3, obtain the ampoule's body diameter, neck diameter D, and total height H through visual recognition; S4, Calculate the compensation value used to correct the actual position of the robotic arm: Compensation value = (Target value - Bottle diameter / 2) - Calibration bias term; S5, based on the compensation value and the bottleneck diameter D, correct the actual bottle cutting coordinate point of the front gripper center position; S6, based on the compensation value and the total height H of the bottle, correct the actual bottle-knocking coordinate point of the center position of the front gripper; S7 inputs the preset robotic arm posture parameters and the calculated actual bottle cutting and knocking coordinates into the robotic arm control system, controlling the robotic arm to first move to the bottle cutting mechanism to perform the bottle cutting operation and then move to the bottle knocking mechanism to perform the bottle knocking operation.
2. The ampoule handling method for an automatic dispensing machine according to claim 1, wherein The process of constructing the XYZ three-dimensional spatial coordinate system for the robotic arm motion is as follows: Set a reference origin, take the horizontal forward direction of the robotic arm as the X-axis, take the horizontal rightward lateral movement direction of the robotic arm as the Y-axis, and take the vertical upward movement direction of the robotic arm as the Z-axis.
3. The ampoule processing method for an automatic dispensing machine according to claim 1, characterized in that, S2 specifically includes the following steps: Based on the set diameter of the bottle, the segments are divided into 3 sections: The first interval is (11, 15.77] mm. The slope is set to 0.1333 and the intercept to 6.1467. At this time, the target value is 0.1333 × bottle diameter + 6.1467. The second interval is (15.77, 18.3] mm. The slope is set to 0.085 and the intercept to 6.
73. At this time, the target value is 0.085 × bottle diameter + 6.
73. The third interval is (18.3, 26] mm. The slope is set to 0.09 and the intercept to 6.
5. At this time, the target value is 0.09 × bottle diameter + 6.
5.
4. The ampoule processing method for an automatic dispensing machine according to claim 1, characterized in that, S5 specifically includes: calculating the actual bottle-cutting coordinates (X2, Y2, Z2) of the center position of the front gripper, where: X2 = X0 + bottleneck diameter D - compensation value; Y2 = Y0; Z2 = Z0 - H + ΔZ1, where ΔZ1 is the gripper height offset value.
5. The ampoule processing method for an automatic dispensing machine according to claim 1, characterized in that, S5 specifically includes: calculating the actual bottle-knocking coordinates (X3, Y3, Z3) of the center position of the front gripper, where: X3 = X1 - compensation value; Y3 = Y1; Z3 = Z1 - (bottle height - ΔZ2), where ΔZ2 is the gripper height offset value.
6. The ampoule processing method for an automatic dispensing machine according to claim 1, characterized in that, Before calculating the compensation value, step S4 also includes the following steps: Determine if the bottle diameter is within the segmented range. If so, calculate the compensation value; otherwise, the robotic arm directly throws out the ampoule, and the feedback information is that the diameter is not within the valid segmented range.
7. The ampoule processing method for an automatic dispensing machine according to claim 1, characterized in that, The robotic arm's pose parameters include its roll angle W, pitch angle P, and yaw angle R in space.
8. An ampoule handling system for an automatic dispensing machine, applicable to the ampoule handling method for an automatic dispensing machine as described in any one of claims 1-7, characterized in that it comprises: The visual recognition module is used to obtain the bottle body diameter, neck diameter D, and total height H of the ampoule; The bottle-cutting mechanism is equipped with a horizontal cutting blade for cutting the neck of the ampoule; The bottle-tapping mechanism is equipped with an electrically driven turntable, on which a bottle-tapping post is eccentrically mounted. The bottle-tapping post is used to tap the ampoule after it has been cut. The robotic arm control system includes a data storage module, a data processing module, and an execution control module. The data processing module has a program for calculating the actual coordinates of bottle cutting and bottle knocking. The data storage module stores all preset calculation parameters and calculation results. The execution control module controls the front gripper to perform the bottle opening operation based on the actual coordinates of bottle cutting and bottle knocking. The front gripper is used to hold the ampoule.
9. An ampoule handling system for an automatic dispensing machine according to claim 8, characterized in that, The front-end gripper includes a first gripper and a second gripper arranged symmetrically on the left and right, and a limiting member disposed between the first gripper and the second gripper. The first gripper and the second gripper are driven by a pneumatic cylinder or an electric cylinder and move towards or away from the limiting member at the same time.