**2. Measurement System**

A schematic of the system components and measurement chain is shown in Figure 1. The system consists of up to eight sensor units and an electronics box containing a microcontroller connected to a PC via USB.

**Figure 1.** Realized measurement chain with indication of communication between system components: sensor array (**left**); microcontroller (**center**); and software running on PC (**right**).

A breakout version (https://www.tindie.com/products/jkicklighter/adns-9800-laser-motionsensor/) of the ADNS-9800 optical sensor and accompanying ADNS-6190 lens (Avago Technologies, Broadcom Ltd., San Jose, CA, USA) was chosen due to its high-end specifications (30 g, 3.8 m/s, programmable maximum 12,000 fps and 8200 cpi). The sensor compares sequentially acquired images to mathematically derive resolution-dependent movement counts for the relative displacement along its two main axes *x* and *y*. Each sensor unit is protected by a case, which also serves as a mounting base for attachment to a prepared location on a prosthetic socket or to a testing bench. Both the protective case and mounting base are fabricated in polylactide (PLA) with a Fused-Deposition-Modeling 3D-printer. The sensors interface with the microcontroller over a Serial-Peripheral-Interface (SPI) connection.

The Arduino Due (Arduino AG, Ivrea, Italy) was chosen as a replacement for the Arduino Uno (Arduino AG, Ivrea, Italy) used in the functional model [16] due to its higher processor and SPI frequencies (64 MHz and up to 42 MHz) as well as compatibility with the existing firmware. It utilizes the sensor's burst mode register reading functionality to continuously acquire movement counts in the sensor's main axes *x* and *y* along with the surface quality (SQUAL-) value from the sensor. The SQUAL-value is a dimensionless value equal to 1/4 of the features observed by the sensor and is an indicator of surface texture. The microcontroller transmits these quantities and a timestamp in *μ*s to a PC via a USB connection at a specified sampling frequency.

Incoming data are received and saved to a binary file by the serial terminal program RealTerm (https://realterm.sourceforge.io/). The measurement process is controlled from a Matlab (MathWorks, Natick, MA, USA) GUI, from which the number of sensors, sampling frequency per sensor and calibration factor are set. The calibration factor is calculated from uncalibrated measurements over

a known distance. After completion of a measurement, the GUI converts movement counts into displacement distance with Δ*d* as the displacement in mm, *c*<sup>x</sup> the movement counts, and *k*<sup>x</sup> a dimensionless, surface-dependent calibration factor:

$$
\Delta d = k\_{\rm x0} \frac{25.4 \text{ mm/inch}}{8200 \text{ cpi}}. \tag{1}
$$

Optimization of the measurement chain with respect to sampling rate is achieved by minimizing register reading times, on-board processing, and the number of bytes transmitted to the PC. The sensor resolution and frame rate are set to their maximum values of 8200 cpi and 12,000 fps. The SPI frequency was set to 2 MHz and the baud rate to 115,200 bps. These modifications increase the system's top frequency from about 62.5 Hz for one sensor unit [16] to approximately 1.3 kHz, to be distributed among all attached sensors.
