MPC8313e GPIOs

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MPC8313e GPIOs

Jump to solution
2,233 Views
medina
Contributor III
  I am trying to use the MPC8313e GPIOs . I toggle them from CodeWarrior. I have verified that the way of accessing the registers is the right one and I have been able to change the registers of other peripherals.

On the other hand I always read '0 ' from the GPIO data register even some GPIOs having pull-up. I configure them as output and try to toggle them writing in its respective register  but do not toggle, I check this by hardware (scope) and by software.

Does anyone have any idea?

Regards,
0 Kudos
1 Solution
927 Views
abartky
Contributor IV

Medina,

 

Here's a thing to check if you haven't already done so.

 

All the GPIO 0-31 functions are multiplexed so you do have to make sure the pin isn't being used for another function.

 

Here are some excertps from the MPC8313 Engineering Reference Manual Rev. 1 07/2007 that may help

 

From section: 3.4 External Signal Description

From Table 3-6 External Signals—Detailed Signal Descriptions

Signal I/O Description: CFG_LBIU_MUX_EN (LA[0:15]/GPIO)

 

Pin type: Input Meaning:

 

Asserted—GPIO ports function according to the values in their configuration registers (this may be LBC or non-LBC functionality).

 

Negated—GPIO ports function as LA[0:15] irrespective of the value in their configuration registers.

 

Also see, 5.3.2.5 System I/O Configuration Register Low (SICRL). Bits 2-13 control if GPIO is enabled or other functions, see table in spec.  The reset values of this register typically default to GPIO, but there may be software and/or board init that is setting this register to enable an alternate function rather than the GPIO you are trying to use.  This register is read/write, so you can check it's current value by reading it.

 

Hope this helps :smileyhappy:

 

- abartky

View solution in original post

0 Kudos
2 Replies
928 Views
abartky
Contributor IV

Medina,

 

Here's a thing to check if you haven't already done so.

 

All the GPIO 0-31 functions are multiplexed so you do have to make sure the pin isn't being used for another function.

 

Here are some excertps from the MPC8313 Engineering Reference Manual Rev. 1 07/2007 that may help

 

From section: 3.4 External Signal Description

From Table 3-6 External Signals—Detailed Signal Descriptions

Signal I/O Description: CFG_LBIU_MUX_EN (LA[0:15]/GPIO)

 

Pin type: Input Meaning:

 

Asserted—GPIO ports function according to the values in their configuration registers (this may be LBC or non-LBC functionality).

 

Negated—GPIO ports function as LA[0:15] irrespective of the value in their configuration registers.

 

Also see, 5.3.2.5 System I/O Configuration Register Low (SICRL). Bits 2-13 control if GPIO is enabled or other functions, see table in spec.  The reset values of this register typically default to GPIO, but there may be software and/or board init that is setting this register to enable an alternate function rather than the GPIO you are trying to use.  This register is read/write, so you can check it's current value by reading it.

 

Hope this helps :smileyhappy:

 

- abartky

0 Kudos
927 Views
medina
Contributor III
Thank you very much abartky. That was the solution.

Regards.

0 Kudos