Optimizing transparency of haptic device through velocity estimation

In this paper, the conception and optimization of a new dual-stage haptic device is described. A particular attention is given to the choice of encoder. Compact, consumer grade, but low resolution encoders are particularly used. An issue arising from this particularity is the deterioration of the velocity measurement when Finite Difference method is used. Moreover, when encoders resolution decreases, velocity estimation becomes noisy. From haptic point of view, this noise destroys the realism of the rendered force. To deal with this problem, numerous methods have been proposed to offer a noiseless estimation. Here, advanced methods such as Low-Pass Filter, First Order Adaptive Windowing, Kalman Filter are proposed. Performances of theses methods are verified and experimentally compared to a conventional finite difference method. Here, we show that Kalman filter and First Order Adaptive Windowing offers a good trade-off between estimation and noise rejection.


I. INTRODUCTION
The human sense of touch operates within four to five orders of magnitude of external loads and with temporal scales ranging from persisting signals down to about one millisecond.This performance enables the elaboration of percepts such as surface textures, collisions, puncturing, and so one, arising from the small-scale mechanics of damage and frictional interactions.This type of tactile sensations is essential to grasping, probing, and manipulating objects in our environment.The design and construction haptic devices able to operate at the limits of human performance remains a challenge.
Our aim is to construct devices that can operate within the above mentioned ranges without introducing spurious signals that are the results of the typical injurious properties of mechanical systems.Such properties include inertia, friction, backlash, and structural dynamics [1].One particular problem is to achieve the simultaneous production of high and low forces in a single device.Limitation in this aspect are due to an in inertia-torque tradeoff in electromagnetic actuators since a large inertia precludes the possibility to render small dynamic forces.
An ideal, completely transparent haptic device would have no mass, infinite bandwidth, and would supply unlimited forces [2].One method to approach this ideal is to match human sensorimotor performance.For instance, the human finger is able to sense vibrations from DC to only approximately 1 kHz [3], [4].A key element is the smallest human detectable force at a fingertip (F shd = 10 −2 N ).
A new type haptic device able to achieve simultaneously low inertia, high forces and wide temporal bandwidth was first introduced in [5], and a complete, compact, and practical system was described in [2].The idea behind this concept is based on a dual-stage architecture employing a large motor to generate continuous forces and a small motor to produce the transients.Because the two motors combine their torques via a viscous coupler that converts slip velocity into force, it is possible to use velocity feedback to mask the dynamics of the large motor from the user.The resulting device is highly transparent and enables users to detect haptic details that are an order of magnitude smaller than with high-performance conventional haptic devices.For example, the system was included in a teleoperation system [6] and used to accurately feel the interaction forces with a water droplet as perceived by an ant [7].
The particularity of the design comes from the viscous clutch.This element allows the output torque to be decoupled from the inertia of the large motor since the torque is proportional to the controlled velocity of the large motor.An issue arising from this approach is the need to accurately estimate the velocity of the rotating shafts.Note that as the device aims to render the haptic feedback at 1 kHz, the controller has to run at least at the same frequency.The problem of a valid measurement at low speeds may be overcome by employing super-high resolution position sensors, but this approach has several drawbacks: These devices have a high cost, are highly sensitive because of the optical process and pose an integration problem as those don't come as a built-in option with the actuators.This issue becomes critical during any effort aimed at bringing the dual-stage haptic device technology to an affordable stage using consumer grade components, since the sensors are the dominant source of cost of the whole system.Figure 1 shows how the velocity estimate deteriorates when encoder resolution decreases from 5 000 to 1 024 increments when using the Finite Differences velocity estimation method.As the number of increments decreases, the uncertainty associated with each increment increases.The variation of the estimate precision decreases proportionally to the encoder resolution.
From haptic point of view, this noise greatly jeopardizes the realism of reproduced signals since the human tactile sense is highly sensitive to minute oscillations and the velocity estimates participate directly in the control signals sent to the motors.
The objective of the present study to to leverage advanced algorithms to compensate for the use of consumer-grade low resolution encoders.Different algorithms are evaluated, including Finite Difference, Low-Pass Filtering, Kalman Filtering with triple integration [8], Kalman filtering with a known model [9], and First Order Adaptive Windowing (FOAW) [10].
The article first describes the dual-stage haptic device technology and a new compact design is presented, then deals with velocity estimation where the aforementioned methods are described and tested.

A. Dual-stage device
The device is based on a dual-stage architecture, similar in design in hi-fi speakers where low and high frequency sounds are output on different channels.
A large motor providing high torque is coupled viscously to a smaller motor with a view to produce the missing transients, see Fig. 2. The output is effectively the sum of torques of both motors.

Small motor Handle
Fig. 2. Dual-stage haptic device described in [2].It is comprised of two motors and a eddy-current viscous coupler.
The coupler transforms the differential slip velocity of the large motor into torque.As a consequence, the handle is decoupled from its effective inertia by slaving the velocity of the large motor to the desired differential slip velocity.A feed-forward path is provided through the small motor to supply the missing transients of the desired input signal.The small motor has very little friction and inertia, so unwanted forces can be kept below the human detection threshold.Readers can find more technical details about this haptic device in [2].

B. Real time control on Linux system
Fig. 3 illustrates the control sytem architecture where the controller receives a torque set-point and uses the signals from the two encoders to generate commands to the motors.The large motor operates in closed loop in order to achieve the desired torque.The control scheme is a polynomial compensator for optimal regulation and tracking.Moreover, the small motor was feed directly with the torque error in order to compensate for the slower response of the large motor.To achieve low jitter sampled data control, the control was implemented on a real-time OS with sampling rate set to 1ï¿oekHz.

C. High transparency
The interface achieved two orders of magnitude of improvement in transparency over existing designs measured in terms of the magnitude of parasitic forces owing to friction and inertia.The improved transparency allowed participants to detect details that were ten times smaller in magnitude than when using a conventional design.However, the cost of the whole system was high, raising the question of whether similar performance could be achieved with lower cost components.

D. Technical improvements
A new design is built in order to improve the robustness of the device.
In this purpose, the continuous stage is replaced by a DCX35L GB KL 36V motor with a factory-mounted compact digital encoder, with 1024 increments.For the transient stage, a DCX22S GB KL 36V motor is used.A 5000 increment hub-disk & encoder (US Digital HUBDISK-1-5000-197-IE ) are mounted on this stage.(see Fig. 4).
These improvements come with a major drawback because of the decrease in the resolution of encoders.1024 increments encoder does not allow for a precise enough estimation of the velocity as shown in the previous section if using basic Finite Difference method at 1 kHz.To deal with this issue, advanced algorithms such as Kalman filter or FOAW can be used to compensate the lack of resolution.

A. Influence of the velocity measurement on rendered torque
The eddy-current clutch generates a torque proportional to the slip velocity.As a result, the accuracy of the rendered torque is proportional to the accuracy of the velocity estimation, and in particular, to the large motor's velocity since the transient stage is held by the user's hand.
In term of haptic interface design, this particularity gives a possibility to define an acceptable error on the slip velocity, matching human sensorimotor performances.This error should be inferior to smallest human detectable force.This inequality is used as a criterion to determine the quality of the different algorithms proposed in this work.
To determine this error, let ω denote the velocity, ∆ω the acceptable velocity error, ∆ω 0 the smallest acceptable velocity error, k the Just-noticeable difference in haptic force, b the damping coefficient of the clutch, D the handle diameter and F shd the smallest human-detectable force at the fingertip.Equation 2, illustrated in figure 5, estimates the minimum tolerance of this error and equation 3 defines the tolerance range.[5], [11]) k 5% (according to [12], [13]) Using the values given in table I and 2, the smallest acceptable velocity error is ∆ω 0 = 0.36 rad/s.In addition to this value, the range estimated via 3 is used to asses the quality of the methods used in this article, as pointed further in figures 6 and 7.

B. Finite difference
The Finite Difference method estimates the velocity by comparing the current position to the previous one at each iteration.This algorithm is sometimes called the Lines per Period estimator [14] because the velocity is estimated by counting the number of encoder lines detected during a sample time following the equation 4.
where T s , is the sampling time and θ is the position output from the encoder.This algorithm is precise for high velocity as the differences between θ(t) and θ(t−1) become significant.
For this method, the achievable resolution is linked to the number of increments and the sample rate by the equation 5. Smallest achievable measurement is a single increment during a sampling period T s .In the case of a quadrature encoder the resolution is 4 times number of increments N inc as reported in equation 5.
Smallest measurable velocity for different encoders with a sampling rate of 1 kHz are listed in table II.The force resolution represents the smallest renderable force, calculated using the viscous coefficient of the clutch.As the tableII shows, the smallest acceptable velocity reported in subsection III-A cannot be reached when finite difference method is used with for example on a 1024 increments encoder.Furthermore, the noise in the speed estimation resulting from this method deteriorates the realism of the haptic feedback as variations are far superior to human detection threshold.

C. Low-Pass Filter
As shown in Fig 1, the previous method introduces noise in low speeds.The most intuitive solution to filter this high frequency noise is to use a Low-Pass Filter.The filter takes as input the Finite Difference calculation and the cutoff frequency is chosen in order to filter without suppressing too much information, around the sampling frequency of the controller.High frequencies, where the most of the noise spectra is located gets rejected, giving a smoother estimation of the velocity.However, this method introduces perceptible delay in system's response and decreases the stiffness that can be rendered by the haptic device, as depicted in Fig. 7.Moreover, the high frequency range contains also haptic information which gets lost in filtering.

D. First Order Adaptive Windowing
the First Order Adaptive Windowing (FOAW) method is an interesting alternative to low-pass filter and can be used to filter the noise while avoiding to suppress the information [10].This algorithm estimates the velocity by fitting on a limited number of samples.The number of samples is dynamically calculated trough a margin on the noise estimate.The fitting can be carried out by different techniques, with little impact on the results in the present case.The best-fit-FOAW further improves the quality of the velocity estimation, being less prone to overshoots.
The filter functions as follows: 1) Set i = 1 2) Set y k as the last sample and y k−i as the ith before y k .3) Calculate b i , slope of the line passing through y k and y k−i from equation 6.
4) Check whether the line passes through all points inside the window within the uncertainty band of each point.5) If so, set i=i+1 and GOTO step 3. Else the speed is returned, ω = b i .The algorithm suppress effectively high variations and introduces only a small latency.The acceptable error margin should be similar to human detection threshold.Fig. 7 shows that the delay introduced is negligible, especially compared to low-pass filtering.

E. Kalman Filter
Kalman filtering is a predictive approach, based on the use of a mathematical model of the system.The accuracy of the model is directly linked to the quality of the filter.The system is described by discrete stochastic dynamical equations [9].
Two different models are compared.The first one is basic triple integration between the acceleration , velocity and the position, without taking into account the mechanical parameters of the system.The second model is based on a faithful identification of these parameters.
1) Triple integrator: In this model the state vector x is the angular position, the velocity and acceleration [10], [8]: The model 9 where the position is derivated twice to sequentially estimate the velocity then acceleration can be written as The discrete equations are: withG the identity matrix in this case.The process noise w k = w 1 w 2 w 3 T and the measurement noise e k are assumed zero mean white Gaussians.The covariance matrix of The variance on the measurement error is a scalar denoted r.
Let xk,l be the estimate of x at the time k knowing x at the time l.P is the error covariance matrix.The discrete-time Kalman is then described by The resulting model has a smoother variation because the fast dynamics of the acceleration are filtered.In case of large variations the filter will privilege the real-time measurements and for small variations it will rely on the model.
2) Realistic model: The previous model doesn't take into account the intrinsic parameters of the device.Its mechanical model can be written trough generated and resistive torquesT m and T c : With J the inertia of the large motor, K t the torque constant, I the set-point current, R the motor internal resistance and b the damping coefficient of the clutch.Taking the same state vector x then previously, the system is expressed as: In the setup, the motor is powered with a current amplifier, thus the current is known and is directly injected in the model, instead of predicting it using the voltage: The discrete-time Kalman filter is then the same as described in (12) with the exception of the first equation expressed with I k , the current sent to the motor.
The realistic model, in comparison to the triple integration, would exhibit lesser latency because of the prediction of the motors response through the current input.This behavior is clearly visible in Fig. 7.

F. Discussion
A second encoder is mounted on the large motor (US Digital EM2 hubdisk with 5000 increments) to provide the reference measurement.The different algorithms are implemented in Scilab on a Linux Real Time environment.They are executed simultaneously hence they operate on the same input signal.To ensure that the control does not privileges one particular algorithm, the closed loop set-point is the speed measured by the reference encoder.The response of the different algorithms are depicted in Fig. 6 and 7, with the confidence interval defined in III-A obtained with the reference encoder.
The response time is an important criterion for the device.The beginning of the response to a step current is shown in figure 6.The Low-Pass filter and the Triple integrator Kalman exhibit both a significant visible latency.Otherwise, other algorithms have similar results.
Figure 7 illustrates the estimation on the permanent regime, on a 15ms period.Finite Difference estimation exhibits significant oscillations with some of the measurements outside the interval.These would result on a perceptible vibration on the haptic feedback.The low-pass filter is clearly not adapted as it does not respect the confidence interval.The Kalman filter with triple integrator produces irons out the variations of the finite difference, but it is not accurate enough although better than the low-pass filter.In practice this error results on an increased perceptible inertia, coupled to the delay of the signal as shown in Fig. 6.The Kalman Filter with the realistic model and the FOAW both fit well in the confidence range.The Kalman Filter with a realistic model produces slightly better results, noticeable on further portions of the signal not shown here.
Figure 8 summarizes the average distance from the confidence interval on a logarithmic scale, in the transient regime and the whole experience.These values are normalized such that the Finite Difference is considered the worst at 100%.FOAW and the Kalman filter with realistic model stand out as best candidates.
The drawback of the Kalman Filter is the requirement on accurate identification of mechanical parameters and produces the best estimation in accuracy without introducing any delay.Nevertheless, this also introduces a dependance on the identified parameters; for example the viscous coupler heats up significantly during operation and its dumping coefficient is modified.This introduces an error in the Kalman estimation and is an eventual weakness of this approach.On the contrary, FOAW gives an estimation practically as good as the Kalman filter, without the sensitivity to intrinsic parameters nor their variations.

IV. CONCLUSION
The device presented here uses a viscous clutch to sum the output torque of large motor, which produces the permanent part of the haptic feedback, with a smaller one which fills in for the transients.As the large motor's output torque is transmitted through its velocity, an accurate estimation is required in both high and low speeds for a high quality haptic perception.Nevertheless, the control of the device runs at 1 kHz sampling fir the same reason.As a consequence, a faithful measurement of the velocity requires an encoder with a relatively high number of increments.These components are considered rather exotic and difficult to integrate in a cost-effective scheme.
The approach pursued here proposes to estimate the velocity on a encoder with a small number of increments, typically 1024, as it can be industrially integrated into the actuator.Several estimation techniques are implemented and compared.Among these, the Kalman filter using a realistic model with the prior identification if mechanical parameters gives satisfactory results.The error of the estimation is beyond the human detection threshold.However an eventual variation on the parameters, especially on the coupler, introduces a non negligible error on the estimation.The workaround to this issue would be to include the behavior of the coupler into the model ans estimate its dumping coefficient along the velocity, or toi rely on e temperature measurement on the coupler.FOAW method, on the other hand prodices an estimation nearly as good as the Kalma filter without these complications.
These two algorithms are shown to accurately estimate the velocity on a 1024 increments encoder, running at 1kHz.Form a user point of view the haptic perception is the same quality then the previous prototype.

Fig. 4 .
Fig. 4. The enhanced version of the haptic device.

Fig. 5 .
Fig. 5. Force transmission from the large motor to the user's finger through the viscous coupler.

Fig. 6 .Fig. 7 .
Fig. 6.Response to a step current.Only the neighborhood of the initial instant is shown

TABLE I NUMERICAL
VALUES FOR b, D, F shd AND k

TABLE II SMALLEST
MEASURABLE VELOCITY.