PSoC62 SCB Interface Swap

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
JoPa_4215136
Level 1
Level 1
First like given Welcome!

Hello together

Is there a possibility to dynamical swap interface or instance in a SCB ?

Example: SCB 0 has scb[0].i2c_scl:0 and scb[0].i2c_scl:1.

I can only map one pin to either scb[0].i2c_scl:0 or scb[0].i2c_scl:1. Is there a way to multiplex them ?

I think that PSoC4 had some unconfigured SCB with this feature.

Thanks a lot

0 Likes
1 Solution

Hi,

>>"If im running I2C on Pin 13.0/Pin 13.1 should i firstly disconnect these pin from SCB with HSIOM_PRTx_PORT_SEL and than attach P12.0/Pin12.1 ?"

--> Yes. You can change the HSIOM mode of pins 13.0/13.1to firmware driven or High impedance analog. And then convert the mode of P12.0 and P12.1 to SCB pins.

>>"So i can swap these pins in run time only by manipulate the HSIOM_PRTx_PORT_SEL ?"

--> Yes. You can do this in runtime.

If you are using PSoC Creator, you can see the initial HSIOM setting of the port (settings given in .cydwr window) in System_init() function call inside cy_fitter_cfg.c file.

Hope this response answers to your questions. Else, please reply.

Thanks

Ganesh

View solution in original post

0 Likes
3 Replies
VenkataD_41
Moderator
Moderator
Moderator
750 replies posted 500 replies posted 250 solutions authored

Hi,

Can you please elaborate more regarding your query?

1. What is your application and what do you exactly mean by multiplexing? or what are the expected results when you multiplex?

2. Which IDE are you using? What is the MPN of the part you are using?

As per my understanding, you want to dynamically switch a pin from connecting to SCB and other component in run time. If that is the case it is possible under certain limitations.

Please refer the GPIO cell architecture from the image below. Each physical pin is routed to different internal components through a multiplexer/demultiplexer which can be configured through HSIOM_PRTx_PORT_SEL register. Here 'x' refers to post.

GPIO_cell.PNG

Please see the Pins table in device datasheet which says that what are the possible multiplexing options for that particular pin.

routing.PNG

Please refer register TRM for  HSIOM_PRTx_PORT_SEL register to get information on how to select different alternate routings of the pin.

Hope this helps! Please respond if you have any queries/need other information.

Thanks

Ganesh

0 Likes

Hi Ganesh

1. What is your application and what do you exactly mean by multiplexing? or what are the expected results when you multiplex?

I would like to attach all pin which have I2C capability to a physical port. So PSoC62 has 9 SCB but if you look in the attached table 5: "Multiple alternate functions" column ACT7 you see, there are 15 I2C instance. Some instance share the same SCB so the idea is to multiplex as an example Pin 13.0/Pin 13.1 (scb[6].i2c_scl:1 / scb[6].i2c_sda:1 ) and P12.0/Pin12.1 (scb[6].i2c_scl:0 / scb[6].i2c_sda:0).  As i understand from your explanations it should work by changing HSIOM_PRTx_PORT_SEL.

If im running I2C on Pin 13.0/Pin 13.1 should i firstly disconnect these pin from SCB with HSIOM_PRTx_PORT_SEL and than attach P12.0/Pin12.1 ?

So i can swap these pins in run time only by manipulate the HSIOM_PRTx_PORT_SEL ?

2.Which IDE are you using? What is the MPN of the part you are using?

I work with PSoC Creator and use in my design CY8C6247BZI-D54.

Thank you

0 Likes

Hi,

>>"If im running I2C on Pin 13.0/Pin 13.1 should i firstly disconnect these pin from SCB with HSIOM_PRTx_PORT_SEL and than attach P12.0/Pin12.1 ?"

--> Yes. You can change the HSIOM mode of pins 13.0/13.1to firmware driven or High impedance analog. And then convert the mode of P12.0 and P12.1 to SCB pins.

>>"So i can swap these pins in run time only by manipulate the HSIOM_PRTx_PORT_SEL ?"

--> Yes. You can do this in runtime.

If you are using PSoC Creator, you can see the initial HSIOM setting of the port (settings given in .cydwr window) in System_init() function call inside cy_fitter_cfg.c file.

Hope this response answers to your questions. Else, please reply.

Thanks

Ganesh

0 Likes