turn on leds in mcf5329

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

turn on leds in mcf5329

1,561 Views
VeronicaFNX
Contributor I
Hello,
 
I wrote a message because I didn´t know how turn on leds in m5329evb.
 
Somebody said to me:
 
"
On the M5329EVB evaluation board, the LEDs are connected to the TIMER port. To flash them, you need to carry out two steps:

(a) Configure the TIMER port for General Purpose output:
    /* Pin assignments for port TIMER            Pins are all GPIO outputs     */    MCF_GPIO_PDDR_TIMER = MCF_GPIO_PDDR_TIMER_PDDR_TIMER3 |                          MCF_GPIO_PDDR_TIMER_PDDR_TIMER2 |                          MCF_GPIO_PDDR_TIMER_PDDR_TIMER1 |                          MCF_GPIO_PDDR_TIMER_PDDR_TIMER0;    MCF_GPIO_PAR_TIMER = 0;
(b) Toggle bits in the PODR_TIMER register to turn the LEDs on and off, e.g:
   /* Sample code: Loop to flash LED */    while (1) {        MCF_GPIO_PODR_TIMER ^= MCF_GPIO_PODR_TIMER_PODR_TIMER3;        for (i = 0; i < 500000; i++)            asm ("nop");    }
"
but I need turn on only a LED, not both simultaneously. That I can do?
Labels (1)
0 Kudos
Reply
2 Replies

576 Views
Kremer
Contributor I
 What about reconfigure the port´s pin as you need for an output and drive it?
0 Kudos
Reply

576 Views
VeronicaFNX
Contributor I
Please, I need aid.
 
Thanks
0 Kudos
Reply