Electronic – How to mount component perpendiculary to PCB

mountpcb-assemblypcb-designsurface-mount

I'm designing small PCB(20mm*20mm) where I'm also limited by height of whole project that can't exceed 20mm. I have to place few sensors on the edge of the PCB but not facing up but facing out of the PCB so pads of sensors are perpendicular to the PCB.

Not the real design I haven't designed this part yet but describes what I'd like to do.

My question:
What is the usual way this is done?

Best Answer

I have seen this done by using two PCBs: a smaller one to hold the component is mounted 90° perpendicular to the other one. Pads on the edge of the small board (both sides) soldered to the main PCB are used as support:

PCB illustration

These pads can consist of electrical connections, with additional redundant pads for strength. An alternative would be to use your choice of connector to interface between the two PCBs:

board-to-board connectors