Using information from @CarlosN's answer I googled "nasa Rover Environmental Monitoring Station (REMS)" and found the following:
and the original paper:
This one is different, but related:
From Gomez-Elvira et al. 2012:
REMS follows Viking design and uses thermal anemometry to record the wind speed also. Hot wire anemometry is based on recording either the amount of power required to heat a wire so that it maintains a constant temperature difference with the ambient (CTA) or to record the temperature of the wire when supplied with a constant amount of power (CPA). The convective power is then calculated, which in turn is used to obtain the wind speed. The REMS wind sensors use a thin film instead of a wire: titanium thin film resistors patterned on the surface of a silicon chip (Domínguez et al. 2008).
How it works: Instead of using a classical hot wire anemometer, a hot film is used in much the same way. By putting multiple films on different faces of the probe, and using multiple probes in different directions, the 3D velocity (speed and direction in both azimuth and altitude) can be inferred later by comparing to CFD simulations.
Fig. 19 Image taken during the REMS integration showing two of the WS boards. Each boom has three boards (Boards 1 and 3 in the sides, and 2 in the lower part of th boom) totally identical. Board 1 and 3 are connected to Board 2 by a flexible circuit and this is connected to the ASIC, in the back of the boom, by another flexible circuit. Each board has four hot dice and one cold die (the four hot dice are in the front of the board and the cold one is in the back). All dice are identical, manufactured in silicon, with three resistors printed on the upper side and thermally isolated from the board by four pillars with a low thermal conductance. In the hot dice, a resistor is used to heat it, another one is used as a sensor to measure the temperature, and the third one is used as reference sensor in the measurement circuit. In the cold die, the only resistor used is the reference resistor (for details see Domínguez et al. 2008). The control loop compares the temperature of the hot dice with that of the cold die, to control the power injected to keep a constant predefined temperature difference (delta temperature) between them. Each board has an additional thermistor on its inside face to monitor the board’s temperature and evaluate the conductive thermal losses of the dice. (Credit: NASA/JPL-Caltech)
Fig. 15 Simulation of the boom model at different yaw angles. These results are used to be compared with real tests in the INTA Mars Linear Tunnel. The fluid was CO2 at 298 K and 72.8 mbar, with wind at 1 m/s. The top image represents a stream in the boom axis direction (yaw = 0°), showing a speed field with the same symmetry as the boom. The lower image represents a 30° incident fluid, in this case it is clear how one board is in the wake area, whilst the other one will see record the wind movement
below x2: Cropped from slides in: Lukasz Kowalski (2009) Contribution to advanced hot wire wind sensing
Update 2022
From Space.com's July 2, 2022 Perseverance Mars rover wind sensor damaged by pebbles, but still operational:
The two approximately ruler-sized wind sensors on Perseverance are encircled by six individual detectors that aim to give accurate readings from any direction, according to materials from NASA's Jet Propulsion Laboratory in California, which manages the rover.
Each of the two main wind sensors is attached to a boom that can unfold to move the sensors away from the rover as it drives, because the car-sized Perseverance does affect wind currents by its own movements through the thin Martian atmosphere, JPL officials stated.
The Perseverance rover deploys one of its wind sensors on the Mars Environmental Dynamics Analyzer (MEDA) during practice activities on Earth in 2019. (Image credit: NASA/JPL-Caltech)