# Application of External Torque Observer and Virtual Force Sensor for a 6-DOF Robot
## 1 Introduction  
With the rise of the automation industry and Industry 4.0, robotic arms have become widely utilized in highly repetitive, dangerous, and high-precision tasks. They not only reduce labor costs but also improve production efficiency and maintain product processing quality. With the advancement of the automation industry, the introduction of tactile sensing into industrial robots will become one of the key developments after machine vision. Applications of tactile sensing include safety collision detection mechanisms during human-robot collaboration and the control of external forces applied to workpieces by equipment to improve processing accuracy.  
Research and applications of robotic arms mostly revolve around utilizing external attachments such as cameras, pressure sensors, or force sensors to make judgments and decisions, perform object recognition and gripping, plan processing procedures, assemble processing components, and polish processed parts. Industrial computers are typically used to control robotic arms by sending control commands to motor drivers and receiving current information from the motors. The current position and speed of the arm can be determined through feedback from the motors. Manufacturers typically use current meters to measure the torque of each axis of the arm. However, the precise external contact force cannot be directly measured. For measuring the contact force of the end effector of a robotic arm, six-axis force sensors are commonly used. However, the price of six-axis force sensors is usually 30% to 50% of the price of the robotic arm. Additionally, industrial computers are generally more expensive than computers used by the general public. As a result, the overall cost becomes a significant burden. It is important to reduce the higher costs associated with industrial computers.  
Using contact force sensors will increase production costs, while establishing a virtual force sensor based on feedback from the robotic arm. It is a cost-effective method. However, precise mechanical structure parameters are required, such as the weight, center of gravity, rotational inertia, and friction coefficient of each axis. However, suppliers of robotic arms often cannot or are unwilling to provide accurate parameters. Therefore, this paper proposes the use of machine learning to estimate torque and create a virtual force sensor. By comparing it with a virtual force sensor established using parameters provided by manufacturers, experiments were designed to verify the feasibility of safety collision detection and hybrid position/force control using the virtual force sensor.  
The price of industrial computers is generally higher than that of computers used by the general public, which can impose a significant financial burden. In order to reduce the high cost of industrial computers, this paper proposes the use of a Raspberry Pi as an upper-level controller, in addition to utilizing personal computers with Windows systems. The Raspberry Pi has advantages such as improved compatibility and a lower price. Therefore, this paper chooses to implement a Real-Time Kernel on the Raspberry Pi. This approach not only fulfills the requirements of EtherCAT motion control for the upper-level controller, but also effectively reduces the cost of the upper-level controller.