3 Replies Latest reply on Apr 3, 2012 8:47 AM by sridhar.m

    Multiple Channel Bootloading

    sridhar.m
          
            Multi- Channel Bootloading with PSoC Creator V2_0    
          
                 
          
                 
          
            With PSoC Creator v2_0, you can now bootload images using multiple channels. You can have multiple communication interfaces in your design and dynamically choose which communication protocol to use for Bootloading the image at run time.    
          
                 
          
            For this you have to choose custom interface in IO component of Bootloader(BL) in system DWR settings and implement the following five communication APIs for each of the communication component used:    
          
                 
          
            CyBtldrCommStart    
          
            CyBtldrCommStop    
          
            CyBtldrCommReset    
          
            CyBtldrCommWrite    
          
            CyBtldrCommRead    
          
                 
          
                 
          
                           
          
                 
          
            As seen from the above figure, USBFS and I2C are used as BL communication component. To switch dynamically during run time, you can use an interrupt that switches to one of the two available IO communication component whenever a flag is set.    
          
                 
          
             For eg:    
          
                 
          
            CY_ISR(MY_ISR_ROUTINE)    
          
            {    
          
               If ( switch_pressed)    
          
            Flag=1;    
          
            }    
          
                 
          
            And implement the instance specific APIs according to the flag set.    
          
                 
          
            For eg:    
          
                 
          
            void CyBtldrCommStart(void)              
          
            {    
          
                        if(Flag==1)          
          
            I2C_1_CyBtldrCommStart();    
          
                            
          
                        else    
          
            USBFS_1_CyBtldrCommStart();          
          
            }    
          
                 
          
                 
          
                 
          
                 
          
             Happy Bootloading