Partner’s Answer.
Yes, the engineer can participate in military related R&D if it is not use for attack.
Participate in military can obtain more sponsorships and develop better products. Gain the sponsor from army or participate in military related R&D doesn't mean you are supporting invasion. In my opinion, engineer is just creating something military need. Take Cryptography for example, its development will not hurt people and it also help people create safe internet and protect people's privacy.