A few things about MEMS devices I have not been able to figure out is: 1. Is the sensing/moving structure actually disconnected from the rest of the device? 2. If so, how does it not get stuck to a side? 3. If it isn't disconnected, doesn't the friction from the connection cause an offset in the reading? 4. How do they etch the structure so that it is disconnected from the layer below?
1. Not entirely, it has two degrees of freedom. Think of it like a bridge.
2. The opposing springs are normally in equilibrium, so in the absence of forces the center mass moves back to position zero.
3. Think of it like a bridge. The points of contact and support are to the sides and stationary, while the spring mass system is suspended in air or in a vacuum.
4. Is simple enough if you start with two disconnected layers of materials, and then etch the top layer. You could also start with a layer of something like photoresist spincoated on the bottom layer, except for the adhesion points...
An interesting real-life scenario was the possibility of helium atoms being able to get inside the MEMS clock of some smartphones and cause the phone to stop working until enough helium can escape.
It would explain why every smart phone I have ever owned has gotten stuck in landscape until I shook it hard enough.
I believe the answer to your question is that the structure is "connected" to form a solid piece of material, but like any real material it isn't perfectly rigid. So it can vibrate, kind of like a tuning fork, and the thinner parts can act as springs. See the diagrams here: https://pmc.ncbi.nlm.nih.gov/articles/PMC9571586/
If you wanted to use such a device as a simple oscillator, you just set it vibrating and measure the oscillation frequency. Since the material isn't perfectly elastic, the vibrations will eventually be damped and die out (I guess this is what you mean by "friction"), so you use a feedback mechanism to keep the oscillation going.
A gyroscope works the same way, except that you use feedback to maintain an oscillation in one axis, and measure how much of that oscillation couples to a different axis. Whatever effect the damping has on the final measurement, I would assume it can be easily calibrated out.
I don't really know how they physically manufacture these devices without damaging the tiny, delicate structures. It's kind of mindblowing that they're so incredibly cheap.