The picture shows one of the historic buildings in the old army town, taken during a visit in 2001.
(See map for location of Ballincollig.)
The following excerpt is from the website Ballincollig Heritage:
“The barracks ...were built between 1806 and 1815 by the British Board of Ordnance. The main Barrack Square was laid out in 1811. The main Barrack Square comprised the four Barrack buildings with a spacious courtyard. There were three entrances into the barracks: the East Gate, the Main Gate and the West Gate. The East Gate led down the hill to the Gunpowder Mills and each entrance was guarded by a sentry.
By 1837, the barracks comprised accommodation for eight officers and over two hundred non-commissioned officers and men. At that time, the barracks were not only used for securing the gunpowder but as a rest station for troops returning from overseas and the preparation of troops going abroad. Later married quarters were added and accommodated sixty eight families.”
The text in italics matches well the situation for John Capper and his wife Ann.
a) He was stationed here between his overseas assignments in Turkey and India.
b) Daughter Anne V. Capper was born in Ballincollig so they may well have lived in the married quarters mentioned.