There is this entry from 1851:
Charles Wilson 54 Overseer Lead Miner b. Sanquhar Wanlockhead, Dumfriesshire
Peter Wilson 23 miner b. Sanquhar Wanlockhead, Dumfriesshire
Mary Paterson 21
Address: Overseer House, Woodhead Lead Mines, Carsphairn, Kirkcudbrightshire
For this family, I think Mary married in 1850 and James joined the church and later married in 1863 in Edinburgh.
A possible death for Charles post 1855 and the start of Scottish official registration of BMDs. If the correct one in 1872 New Abbey, Kirkcudbright, it should include the names of his parents if this info was known to the informant of his death. His son, James Stewart Wilson, was the Minister of New Abbey at this time.
There is an entry in the Wills & Testaments section of Scotlands People (as linked above by Forfarian) which shows:
Charles Wilson
19/9/1872
resided at Woodhead Mine, parish of Carsphairn
Kirkcudbright Sheriff Court
SC16/41/30
If you have further details on Peter, this would help in trying to connect to his extended family and from this try to get details on his parents.
Some background on the Woodhead Mine here
www.carsphairn.org/CarsphairnArchive/files/original/bc1c71e6091c644a1b0655e097d1e1b2.pdfMonica