A couple points:
1) A weapon focus must be handheld. So a spear would work as a focus if you hold it, but not if you throw it. Thrown/projectile weapons can't be foci. (Well, they can, but they lose their bonus once they leave your hand.)
2) Technological items are much harder to enchant than natural items. During the enchanting process, the focus "resists" you as you try to create it. A natural wooden spear would be a 3, while a shock glove or a stun baton might be a 9. That means that, on average, the technological version will roll 2 extra hits to resist you, making it 2 points of Force weaker than the non-technological version. So, yes, this can be done, but there's a price (of effectiveness) to be paid.