Sauté the onion gently in the olive oil or lard in a skillet (nonstick is best) until soft and translucent, along with the pancetta or speck if using.
Add the potatoes and mix together with the onions. Season generously with salt and pepper, then add a glassful of water and cover. Let the potatoes simmer until soft, adding more water if necessary. Uncover and let any remaining liquid evaporate, smashing the potato with a wooden spoon into a very rough purée, leaving some of the potato dice whole.
Add the cheese and fold it well into the potato and onion. Stir from time to time over gentle heat until the cheese melts completely. Continue simmering for another 5-10 minutes, until the mixture has thickened enough that it forms a solid mass.
Now flatten out the mixture and turn the heat up. Let the mixture form a nice brown crust on the bottom, then flip it over and let it brown on the other side, as if you were making a frittata, about 3-5 minutes per side, (Repeat if need be to get a nice crust.)
Serve immediately, while the cheese is still warm and creamy.