The swallow tail design at the top of the walls depict that this castle showed allegiance to the Pope. If it were square at the top, it would depict allegiance to the Emporer.
The slits below the center of the swallow tails were for archers to shoot out of. The archers were well proteced behind the columns.
The lower holes, above the lower arches, were used for dumping boiling water on would-be attackers.