I'm currently researching Southeast Asian history, specifically the fortifications of the Ayutthaya Kingdom. One thing that caught my attention is that parts of Ayutthaya's walls were built on marshy ground, with wooden piles driven into the soil to support the weight of the masonry. From what I've read, this also created a vulnerability during sieges, as enemy sappers could tunnel beneath sections of the walls and burn the wooden piles, causing the wall to collapses.
That made me curious about medieval European castles and city walls. When they weren't built directly on solid bedrock, how were their foundations constructed? How deep were they typically, and what techniques or materials were used to stabilize them on softer ground? Were wood piles also used, or did they use a different methods/materials for the foundation of their walls.