12 Replies Latest reply on Aug 22, 2014 12:58 PM by julio.unigarro


        • 1. Re: jcu

          Use IE of Firefox on this forum, Chrome does not seem to work.




          Regards, Dana.

          • 2. Re: jcu
                Hello, I need to manage records for psoc 5.    
                Any help or example to mask ports and PSoC1 PRT1DR & 0x01.    
                Thank you.   
            • 3. Re: jcu

              can you explain what do you want to achieve?


              And do you have problem with PSoC1 or PSoC5?

              • 4. Re: jcu

                If you are working with PSOC 1 take a look at -








                http://www.cypress.com/?rID=2900     AN2094 - PSoC® 1 - Getting Started with GPIO


                http://www.cypress.com/?rID=39497     Shadow Registers






                Regards, Dana.

                • 5. Re: jcu

                   I need to learn to manage registers in psoc 5.


                  I need some examples.



                  • 6. Re: jcu

                    Some thoughts -




                    1) In Creator, Help, System Reference, System Reference Guide, section 7


                    are the functions for register access. In the device.h file are the register names.




                    2) In the Register TRM for your device there are the definitions of all the registers and their bit


                    fields to control HW.




                    Basically you read modify write registers to set/reset bits, bit fields, etc to effect


                    HW control at more primitive levels.




                    Regrads, Dana.

                    • 7. Re: jcu

                       I want to do the program for a 4x3 matrix keyboard and want to use the records, as follows; 

                          void main (void)    
                            LCD_Char_Start ();    
                            uint8 fil = 0, col = 0, Bin = 0, result = 0;    
                            Matriz_Write (0xF0);    
                            Matriz_Read col = ();    
                            Matriz_Write (0x0F);    
                            Matriz_Read fil = ();    
                            Bin & fil = col;    
                            LCD_Char_Position (1.0);    
                            if (Bin == 0x11) LCD_Char_PrintString ("1");    
                          the problem is not as if setting pins to Pins:    
                          or records:    
                          I want to do it the same way as in PSoC1    
                          PRT1DR = 0xF0; 11110000 // for columns if I press the 1 key.    
                          col = PRT1DR; // Port leo 11110001    
                          PRT1DR = 0x0F; // for rows 00001111    
                          fil = PRT1DR // leo port 00011111si I press the 1 key.    
                          Bin & fil = col; 11110001    
                                                                                = 00010001 is equal to 0x11.    
                          If (Bin == 0x11) result = 1;    
                          I do this but necesoto Psoc 5.    
                          If anyone can help me I appreciate.   
                      • 8. Re: jcu

                        Accessing complete ports in PSoC5 is described in the pin-component and the System Reference Guide (Help - System Reference). You may specify a port containing up to 8 pins and write with a single instruction




                        for example. Reading is done with Result = Port_Read();





                        • 9. Re: jcu

                           I do not understand the configuration of the pins if I have to do it individually or as follows: "Cy_pins" pins 0-7 whit 


                          With a single name for all the cosets of pins. example Matriz for p1.0
















                          So a port but all under a common name "Matrix".

                          • 10. Re: jcu
                            • 11. Re: jcu

                              So just write




                              and all the pins will be set as you want. Make sure that the configuration is set to "Contigous" under tab "Mapping"





                              • 12. Re: jcu

                                This might be of use -










                                Regards, Dana.