Hi,
The fail is no surprise. The board is not suitable for switch mode power supply. I´d call it not suitable for a microcontroller, too.
It doesn´t mean that there is no chance to make it running.
What I mean: The behaviour is not predictable, not stable, not reliable.
* ULN: for sure you use the collectors.
* I don´t see a ceramics capacitor in your whole circuit. Neither in the schematic nor in the photo.
* There is more than "1000uF" or "100uH" of a capacitor/coil specification. Otherwise the datasheet would be very short ;-)
* usually it´s impossible to follow the layout guidelines on a strip board
I´m not familiar with PICs, but from your code I don´t see PortA to be defined at all. So I guess there are pins left floating.
Klaus