10 Replies Latest reply on May 22, 2015 9:28 AM by JoMe_264151

    How to bild a bootable project that stops further bootloading

      Hello,

         

      how to build a bootable project for a PSOC4 device that, if downloaded via bootloader, didn't allow further bootloading. I've finished the final version of my project and now I want to close up the chip, when I deliver my work. At the moment I don't have a programmer and now other prototyping kit, so I have to use the bootloader to download the software. What's the best practice in this case to build the project?

         

      regards

         

      R.N.

        • 1. Re: How to bild a bootable project that stops further bootloading
          JoMe_264151

          Welcome in the forum!

             

          Easiest could be to have a variable in flash set after bootloading to prevent further execution of the bootloader. Have a look at this thread for how to do that.

             

           

             

          Bob

          • 2. Re: How to bild a bootable project that stops further bootloading

            Hi Bob,

               

            maybe your answer is not just what I expacted. I asked for an easy way to configure a project in a way that further bootloading is not possible any more. Or again in other words is it possible to download a normal (not bootloadable) project to a device with a bootloader in way that further bootloading is not possible. Is this possible or not?

               

            best regards

               

            R.N.

            • 3. Re: How to bild a bootable project that stops further bootloading
              JoMe_264151

              The Bootloader is nothing than a special program that runs when the board gets resetted. When you have got a programmer for your PSoC4 there is nothing more you need to overwrite the existing bootloader with a complete project.

                 

              Usual programmer choice is MiniProg3

                 

              + Programs any PSoC

                 

              + Allows Debugging!!! (Breakpoints, variable inspection etc)

                 

              + integrates smoothly into Cypress Creator software

                 

              - Price

                 

              There is a hack showing how to modify a pioneer kit (which is less expensive than a miniprog) to program another PSoC4

                 

              + Price less than 1/3 of a Miniprog3

                 

              - Looks a bit like "Hobbyist programmer"

                 

              - For PSoC4 only

                 

              - can break the Pioneer kit

                 

               

                 

              Hope that this is a better suggestion

                 

              Bob

              • 4. Re: How to bild a bootable project that stops further bootloading

                Hi Bob,

                   

                thanks for your reply. Yes, the best way is to use a Miniprog. But as I mentioned I didn't have one now (hope I will get it soon) and I run out of time. I didn't thought that I will get a problem downloading the final version with the bootloader and then close the chip.

                   

                So, as you don't have any easy suggestions, how to mange this problem, there is no solution, right? It would be good to know that, because then I can stop searching for it.

                   

                best regards

                   

                R.N.

                • 5. Re: How to bild a bootable project that stops further bootloading

                  If you don't have MiniProg to ptogram the bootloader again, then its not possibe to achieve what you want.

                     

                  Even changing the flash settings in bootloadable will not help here sinc the flash settings in bootloader project will be used.

                     

                   

                     

                  Thanks,

                     

                  Keerthi

                  • 6. Re: How to bild a bootable project that stops further bootloading

                    Hi Keerthi,

                       

                    so it is possible to achieve what I want when I change something in the Bootloader project. I use the latest bootloader project from the cypress web page. What I have to change there?

                       

                    regards

                       

                    R.N.

                    • 7. Re: How to bild a bootable project that stops further bootloading
                      JoMe_264151

                      You cannot overwrite the bootloader in a PSoC4 prototyping kit without a programmer. The bootloader is protected and the only thing that will remove bootloader and protection is a complete erase of the chip, but that is leaving you with a dumb chip and still no programmer.

                         

                       

                         

                      You need a programmer to overwrite the bootloader.

                         

                       

                         

                       

                         

                      Bob

                      • 8. Re: How to bild a bootable project that stops further bootloading

                        Hi Bob,

                           

                        thanks, for the clear and unmistakable answer ;-)

                           

                        But, if I cannot override the bootloader by bootloading, why I have to include a bootloader to a bootloadable project. If that bootloader didn't replace the old one, I can include any code as a dummy bootloader. That makes no sense for me.

                           

                        And maybe for the next bootloader version it would be a good idea to have an option in the bootlader to switch it off in a PSoC creator configuration (yes, of course with a microsoft style warning and double question if you realy, realy want to do that)

                           

                        regards

                           

                        R.N.

                        • 9. Re: How to bild a bootable project that stops further bootloading
                          JoMe_264151

                          The bootloadable gets kind of linked to the existing bootloader. Easiest is the size of a bootloader which may vary from the used interface and other capabilities and the start (entry point) of the bootloadable which is wanted to follow directly after the Bootloader to waste no flash. This is the reason why you specify the location of two bootloader-files, the .hex and the other one I've forgotten. Hope that helps clearing your question.

                             

                          And: No, the bootloader will not be switched off, since this might leave a user with an unusable board. So you better remove from your CY8CKIT-049-42xx board the switch that activates the bootloader, so nobody will be able to reprogram your device.

                             

                           EDIT: You do not have to include a bootloader to your bootloadable project, you only have to specify which bootloader you use.

                             

                          Bob

                          • 10. Re: How to bild a bootable project that stops further bootloading
                            JoMe_264151

                            I could lend you a MiniProg3, where in Germany are you located, I live near Bremen...

                               

                            Future electronics has got them on stock, but not sure whether stock is located in Germany. Phone call would help

                               

                             

                               

                             

                               

                            Bob