1 Reply Latest reply on Oct 29, 2019 9:10 PM by DheerajK_81

    Using Multiple MiniProgs on Linux via CLI

    JoGr_3160431

      Hello,

       

      Sorry if this is documented somewhere that I'm just not aware of. I'm using a Linux box to configure a system that includes 2 PSoC 6 devices that I intend to use two separate MiniProgs to configure. I have the Cypress Programmer installed (2.0.0.355). When I use the GUI, I can see the handy drop down to select which programmer I want to use. Under the command line, I have everything working such that I can erase and program a PSoC using the examples given in the CLI User Guide, but I have no clue which MiniProg it will chose or how to change that decision. Any help on making a more specific command/file than the example so that I can have to miniprogs connected and program each of them individually would be greatly appreciated.

       

      Best,
      Josh

        • 1. Re: Using Multiple MiniProgs on Linux via CLI
          DheerajK_81

          The solution is to specify the correct serial number of the desired  MP4 device in the CLI script. The simple way to find out serial number is to use the CYP GUI:

          • Run GUI
          • In the Log (view) you can find info about “Connected” devices
          • In my case there are 2 devices: MP4 (serial 0E13188B02237400) and KP3 (serial 1616176C03227400)

          oleksiy1.jpg

          • The last part in the device description is the actual serial number (SN)
          • Copy the SN of the interested device to clipboard (MP4 in my case  has serial: 0E13188B02237400, selected in the figure below)

          oleksiy2.jpg

           

          • Close CYP GUI app.
          • Run terminal and go to the openocd/bin directory
          • Modify your script to include the serial number of the device using command “cmsis_dap_serial SN”.  For example to select my MP4 device I include command  “cmsis_dap_serial 0E13188B02237400” into the script after specifying the interface. (Note: the position of it is important)

           

          ./openocd -s ../scripts -c "interface kitprog3; cmsis_dap_serial 0E13188B02237400; transport select swd; adapter_khz 1500" -f target/psoc6.cfg -c "init; reset init; flash erase_sector 0 0 last; shutdown"

          olesiy3.jpg

           

          Regards,

          Dheeraj

          1 of 1 people found this helpful