1. Field of the Invention
The invention relates to a robot control system and a control method for a robot, and in particular to change of the function of a sensor unit.
2. Description of Related Art
Acceleration sensors and angular velocity sensors are used for attitude control of a mobile body of a robot or the like. If three orthogonal axes are set up, i.e., an X axis, a Y axis, and a Z axis, then the accelerations in these three axial directions are detected by three acceleration sensors, and the angular velocities around these three axes are detected by three angular velocity sensors. The angles around these axes, i.e., the attitude angles, are obtained by time integration of the outputs of the angular velocity sensors, and thereby a roll angle, a pitch angle, and a yaw angle are calculated.
In Japanese Patent Application Publication No. JP-A-2004-268730, a technique is disclosed for performing attitude control by using acceleration data and attitude data outputted from gyro sensors.
Furthermore, in Japanese Patent Application Publication No. JP-A-11-316732, a technique is described in which, as commands which are transmitted from a host to a peripheral processing device, there are provided an execution command which performs designation of an operation, and an execution command which does not perform designation of any operation, and it is made so that it is possible to change this operation, only at times when change of operation according to these two types of execution command is required.
When performing attitude control using acceleration data and/or attitude data, there is a requirement for accuracy of the attitude angles, but, since these attitude angles are obtained by time integration, sometimes it happens that the accuracy decreases due to integration of the errors. Thus, a requirement arises for resetting the attitude angles to 0°, or to predetermined angles, at some timing.
Furthermore, since the operational characteristics of the sensors are different according to the type of the robot whose attitude must be controlled, and according to the fitting positions or the fitting orientations of the sensors, there may be a requirement for adjusting the operational characteristics for each sensor individually. For example, it may be desirable to adjust the time constant of a filter to the most suitable value, or the like.
In order to respond to this type of request, it may be considered to stop the robot, and to again restart the operation of the robot after the characteristics of the sensor units have been changed; but it is desirable to be able to change the characteristics of the sensor units without delay during the operation of the robot. For example since, when the robot is performing some specific operation, only some specific sensor outputs are required among the plurality of sensor outputs which are being outputted from the sensor units, accordingly it would be desirable to be able to change the sensor units over directly to a characteristic in which only those sensor outputs are transmitted. Although in the above described Japanese Patent Application Publication No. JP-A-11-316732, it is possible to change over the operation as well, it is difficult to change over the operation in real time.
It is an object of the invention to provide a robot control system and a control method for a robot, with which it is possible to change the characteristics (or the function) of a sensor unit which is installed in the robot immediately.
A robot control system according to a first aspect of the invention, comprises a main processor, and a sensor unit which transmits sensor output to the main processor. The sensor unit comprises a processor, and a memory which comprises a first region and a second region for storing parameters which stipulate the operation of the processor, and the processor, along with transmitting the sensor output to the main processor during a transmission period within a predetermined period by using the parameters which are stored in one of the first region or the second region of the memory, also receives update parameters from the main processor during the remainder of the reception period within the predetermined period, and stores them in the other one of the first region or the second region, and thereafter transmits the sensor output to the main processor using the update parameters.
With the robot control system of the first aspect, the sensor unit transmits the sensor output to the main processor of the robot based upon the parameters which are stored in either one of the first region or the second region of the memory (for example, suppose that it is the first region), but, when update parameters are received from the main processor in the reception period of the predetermined period, it stores these update parameters in the second region. And the processor of the sensor unit, instead of the parameters which are stored in the first region (the default parameters), operates based upon the update parameters which have thus been stored in the second region. By transmitting the update parameters from the main processor to the sensor unit during the reception period, even during the operation of the robot, and by storing the update parameters in a different region from the first region of the memory, and changing over the parameters from the default to the update parameters, it is possible to change the characteristics or the function of the sensor unit very quickly. When yet further update parameters are transmitted from the main processor during the operation of the update parameters which have been stored in the second region, these update parameters are stored, this time, in the first region. When these new update parameters have been stored, the sensor unit operates according to the new update parameters which have thus been stored in the first region, instead of according to the update parameters which have been stored in the second region. By thus using the first region and the second region of the memory in an alternating and complementary manner, it is possible to change the characteristics or the function of the sensor unit in real time as desired.
A control method according to a second aspect of the invention is for a robot comprises a main processor, and a sensor unit which transmits sensor output to the main processor. The sensor unit comprises a processor, and a memory which comprises a first region and a second region for storing parameters which stipulate the operation of the processor. The control method comprising: transmitting the sensor output to the main processor during a transmission period within a predetermined period by using the parameters which are stored in one of the first region or the second region of the memory; receiving update parameters from the main processor during the remainder of the reception period within the predetermined period, and storing the update parameters in the other one of the first region or the second region; and thereafter transmitting the sensor output to the main processor using the update parameters.
According to the invention, it is possible to change the characteristics (or the function) of a sensor unit which is installed in the robot immediately.
The foregoing and further objects, features and advantages of the invention will become apparent from the following description of example embodiments with reference to the accompanying drawings, wherein the same or corresponding portion are denoted by the same reference numerals and wherein:
In the following, an embodiment of the invention will be explained with reference to the drawings.
The sensor unit 10 comprises a sensor 15 which is an acceleration sensor or an angular velocity sensor or the like, a RAM 16, a ROM 18, a driver 20, and a CPU 22.
The ROM 18 stores an OS (operating system) or a program in which is written execution processing for the sensor unit 10. In this program, there are included parameters which change over the type of the sensor output to be transmitted to the robot CPU 12 or a reset function, or which set the time constant of an internal filter or the like. The ROM 18 is a non-volatile memory which can be rewritten, such as a flash ROM or the like.
The RAM 16 stores parameters which have been stored in the ROM 18. In other words, during boot operation when the power supply is turned on, the parameters which are stored in the ROM 18 are read out and are written (i.e., are loaded) into the RAM 16, and predetermined processing is then performed by reading out the parameters which are written in the RAM 16. The CPU 22 writes these parameters which have been read out from the ROM 18 in a specified region of the RAM 16. In this embodiment, this specified region is termed the “first region”. For this first region, its start address (physical address) and its end address may be fixedly set in advance within the RAM 16; or, alternatively, they may be alterable.
According to the parameters which have been read out from the RAM 16, the CPU 22 selects, from among the various types of sensor output which have been inputted from the sensor 15, those of the sensor outputs which are set by the parameters, and transmits them to the robot CPU 12 via the driver 20. The driver 20 may be, for example, a RS-232C driver, but it is not limited thereto; it may alternatively be USB, RS422, IEEE1394, or the like. The CPU 22 transmits the sensor output data out to the serial line via the driver 20, but transmits this data only during a transmission period, which is a portion of a predetermined control period. The remainder of the predetermined control period is allocated as a reception period, during which the CPU 22 receives data which has been transmitted from the robot CPU 12 via the serial data line 14.
In
On the other hand, as shown in
The time series of the operation of the sensor unit 10 is shown in
On the other hand, during performing of processing according to the update parameters which have been stored in the second region as shown in
As explained above, with this embodiment, even while the robot is operating, it is possible for the robot CPU 12 to transmit the update parameters and update command to the sensor unit 10 during the reception period within the control period, and it is possible for the sensor unit 10 to store the update parameters in a different region of the
RAM 16, and to perform processing to changeover from the default parameters to the update parameters upon triggering by receipt of an update command; and it is accordingly possible to change the characteristics or the function of the sensor unit 10 quickly, and moreover in a simple and easy manner.
When such change is performed repeatedly, in order to maintain the history of previous changes of the parameters, after having changed over the operation region of the main processor to the new active region, the contents thereof are immediately copied to the inactive region. The history of the changes to the parameters is maintained due to the fact that the next change of parameters is added onto and written into the inactive region which has been copied. Here, it is not necessary for all of the data in the active region to be copied to the inactive region; it is desirable to shorten the time required for the operation by copying only that portion which has changed, since the same beneficial effect can be obtained.
It should be understood that, for robot control or the like, it is necessary that the calculation speed interior to the sensor should be extremely fast, and that the calculation should be performed accurately with respect to time. When, for example, calculating the angle from the angular velocity, the angle is obtained by integrating the output from the angular velocity sensor, but this must be performed accurately in the series n, n+1, n+2, with the integration period At for processing discrete data being accurate. On the other hand, the communication to receive output of the sensor data and changes of settings takes a considerable amount of time, and moreover fluctuates according to the contents of the data and the communication environment. Accordingly when, simultaneously with receipt of the parameter settings from the main processor, the details of the calculation processing on the sensor side change, then the calculation period and the calculation timing become disturbed, and the accuracy of the data is lost. For example, At may no longer be constant, or an omission may occur in the data processing steps like n, n+1, n+3, . . . . But since, according to the invention, it is possible to determine the timing of actual operation according to the change of parameters by a timing interior to the sensor, accordingly it is possible to keep the calculation period and the calculation timing constant. Furthermore, although it is necessary to pause the calculation during change of the parameters since the parameters are not definite, with the method according to the invention, until the change of the parameters is definite, the interior calculation is performed using the parameters in the first region 16a established directly previously, and the parameters during the change are written into the second region 16b. Since, by using the second region 16b in which the changed parameters have been set up in the next calculation timing, it is made possible to perform the calculation continuously while preventing delay or standstill in the calculation time, accordingly it is possible to obtain a sensor output suitable for real time control.
The invention is not to be considered as being limited to the embodiment described above; there are various alternative possibilities. For example although, with this embodiment, in consideration of the amount of data in the update parameters, the update parameters were divided into packets, and these packets were transmitted over a plurality of control periods, it would also be acceptable to arranged to transmit the update parameters during the reception period within a single control period.
Furthermore, although in this embodiment, as shown in
Moreover, although in this embodiment, as shown in
With the robot control system of this embodiment, it is possible to implement the characteristics or the functions of the sensor unit 10 almost in real time. If resetting of the attitude angle is to be executed periodically, or during robot stopping operation, then the robot CPU 12 transmits a reset command during the reception period of the control period periodically, or during robot stopping operation. The CPU 22 receives this reset command, and resets the attitude angle output of the sensor 15 to zero. An automatic compensation function during robot stopping operation is provided to the sensor unit 10, and, when setting with the parameters whether this function is to be effective or is to be ineffective, the robot CPU 12 transmits the update parameters according to a command from the user. The CPU 22 changes over the default parameters (functionally ineffective) to the update parameters (functionally effective), and subsequently, each time it detects stopping of the robot, it automatically performs zero point output compensation or the like for the robot.
Number | Date | Country | Kind |
---|---|---|---|
2005-223511 | Aug 2005 | JP | national |
Filing Document | Filing Date | Country | Kind | 371c Date |
---|---|---|---|---|
PCT/IB2006/002086 | 8/1/2006 | WO | 00 | 1/29/2008 |