Diffs
Torx is optimal for delivering torque without stripping out the head, when the assembly is robotised with controlled-torque.
Philips is optimised to minimise strip-out damage during human assembly, when the tool *does* slip. Hex strips out very easily, particularly when small, but is essential in limited-access; *large* hex bolts you will see everywhere because they are so good at what they do. They minimise human assembly cost for *long* bolts, because you just spin the Allan key in a way that you just can’t with any screwdriver, and that’s worth often an x3 in human assembly cost. Just try putting together flat pack furniture with 10cm Philips head bolts, and then come back to “we should have standard head type” - it’s pain in the backside. Flat performs poorly as a screw, *particularly* when the screwdriver is low quality and/or not matched to the slot width. It is however *much, much cheaper* to produce the screw itself - usually now seen in situations where the production volume is locally small enough that nobody cares about the human assembly cost, like backstreet Bangladesh sweatshops with everyone sitting on the floor.
Not surprisingly, the answer is “which head you design in, depends on the application, method of assembly, and what you are trying to optimise for”. And, just like any other application, if you choose to optimise for home repairability, not only is the answer different, then you necessarily compromise on the other design goals. For example, if you don’t want Torx, you immediately require the screw to become much larger to deliver the same closing torque (clue is in the name!), a larger footprint on the PCB, and a larger device overall just to accomodate the screws.
If you decide to require flat-heads, to maximise the probability of the bloke at home having the right screwdriver, you are also pushing the economic incentive *heavily* away from robotised assembly, towards the Bangladeshi sweatshop with women twiddling the screwdriver on their bare feet.