Hi guys, I need your help.
I own an Arduino Uno R3, I purchased some ATmega328P "virgins" and then I need to reprogram them.
But I must protect the firmware that I have made to avoid attempts of reads / copies.
I've read that you can protect your firmware by setting the appropriate "fuse bits" and "lock bits", but I have the ideas a bit confused and not know where to start.
I tell you the material I:
No. 3 Arduino Uno R3
No. 1 AVRISP MKII Programmer (Atmel)
No. 1 AVR Studio 4
No. 1 AVR Dude
Please help me, I was stuck and I do not want to risk blocking / damaging my ATmega328P mistakenly setting values.
Rather than locking the chip with a fuse bit, consider making it unintelligible. In other words, encrypt your code using a strong key and use a core which decrypts the code, as needed, during execution.
The problem is that you will run into legal issues by any approach due to creating closed-source software for open-source hardware. Basically, many cores and libraries will be legally unusable to you if they are open-source or have any publishing or sharing requirements. In such a case, you will need to create your libraries and core from the ground up to avoid legal disputes. And even still, you will probably want to seek the advice of a lawyer.
I thank you for your response and for your advice.
Virtually have no legal problems What should I avoid?
I still have to use my ATmega328P in "standalone" mode.
That is: I I program ATmega328P installed on the electronic board "Arduino UNO R3", but then I will take away, and will install in my motherboard, made by me (acid etching, electronic tracks, new components).
So is it legal?
I remember that the Arduino environment has been created to give hobbyists a chance to perform the tests, tests on electronic boards "Arduino" and then use the ATmega328P independently, by installing the chip in a personal electronic board.
Program the board the use any isp programmer and avrdude (or other tool, ex extremeburneravr ) to set the lock bits as you want them to be. If you use bootloader, it's more complicated. You may also choose to disable spi programming and/or reset to throw further roadblocks in the way of others, but then you can't reprogram it as easily yourself. You should really search the forum for more info - we go over this here at least once a month.
It depends on which and whose Arduino core and Arduino libraries you use and it depends on what your final product is used for and whether that final product is used or sold commercially. Just because you place the chip into your own circuit board does not mean that you automatically have the rights to use other people's core or library to assist your closed-source software. If you software is closed-source, all software you borrow and use in conjunction with it must also closed-source friendly.
It is a waste of time.
If someone is smart enough to copy code they are smart enough to write code.
Anyone in software can simply write new code to do the exactly the same thing as your code.
It isn't unique.
Hello guys, you are really kind and helpful, this is a great pleasure.
Then I'll explain in a more simple:
I have to create a new track, built by me (engraving, new layout, new pcb, new and different components), then I would sell.
I will have to use only the ATmega328P for managing the functions (In / Out) and Atmel MEGA16U2 for transmission usb / serial.
I will not use the Arduino libraries, those are not necessary.
Probably they will not need even the bootloader.
I want to use the "Arduino UNO R3" tab only to program in ICSP mode, my new ATmega328P and Atmel MEGA16U2 (virgins):
Inside of my new ATmega328P will be my firmware, previously programmed by Arduino ICSP.
Inside of my new Atmel MEGA16U2 there will be the original firmware (to Arduino, for the management of functions (In / Out), previously programmed by Arduino ICSP.
After programming, I'll move the two microcontrollers in my new board PCB.
I have to create a new track, built by me (engraving, new layout, new pcb, new and different components), then I would sell.I will not use the Arduino libraries, those are not necessary.
If you do all this why are you stuck to arduino ICSP to program it?
I will put my money that the IDE where you program your "independent" code from arduino will have a internal programmer tool to simply flash the chip.(Atmel Studio, mikroC PRO for AVR ...)
I pretty much I bought the AVRISP MKII programmer.
Tell me: what do you recommend software (avrdude or AVR studio)?
I do not know if it is advisable to switch the bootloader or not, in my ATmega328P.
My intention today is to use the Arduino UNO R3 board to only perform the programming phase with AVRISP MKII (ICSP), then I remove the chip and install it in my personal board.
I do not know how to get started, I need your help.
I need to get is: ATmega328P with read / write protection.