I want to give somebody a project, but i used my own libraries on that and i want to protect my code. I'm currently working with C in STM32 systems. What can i do?


closed as off-topic by Chris Stratton, pipe, duskwuff, Matt Young, Elliot Alderson Aug 17 at 21:42

  • This question does not appear to be about electronics design within the scope defined in the help center.
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 2
    \$\begingroup\$ That's an agreement you need to make before your employer gets access to the code, and preferably before you start working there. \$\endgroup\$ – TimWescott Aug 17 at 21:23
  • 2
    \$\begingroup\$ Obfuscate the code and let them have it. See stunnix.com/prod/cxxo for example. \$\endgroup\$ – Transistor Aug 17 at 21:32
  • 6
    \$\begingroup\$ For employees working in software development, providing your employer with the complete source code for the application you are writing for them is generally considered a condition of employment. If you are unwilling to do this, most companies will not hire you. \$\endgroup\$ – duskwuff Aug 17 at 21:38
  • 3
    \$\begingroup\$ why are your personal libraries on a company computer? \$\endgroup\$ – jsotola Aug 17 at 22:09
  • 2
    \$\begingroup\$ Such a libraries are rather easy to write and it does not make any sense to hide them. You were probably employed because you had previous experience with those devices and it is the part of this experience. BTW this kind of libraries (and it is not the revolutionary method of detecting something for example) is even hard to copyright or patent as all the methods were used hundreds (or rather thousands) times before \$\endgroup\$ – P__J__ Aug 18 at 10:00

Obfuscate the code and let them have it. See Stunnix for example.

(I have no idea how good this is and have never had to do such a terrible thing!)

To be somewhat fair to your employers you should document what the libraries do, what the inputs and outputs are, etc.

  • 1
    \$\begingroup\$ Extremely bad idea. If I was supplied by by my employee with the obfuscated code, I definitely would never trust him again and immediately start search for the replacement. \$\endgroup\$ – P__J__ Aug 18 at 9:55

Not the answer you're looking for? Browse other questions tagged or ask your own question.