hi
i am Karthikeyan J(student).
i tried to enable all GPIO pins in a layout of LPC54628[OM13098] Board. but i cant enable all pins in a single line(0xffffffffU) 32bit.
i can enable pins one by one.
FOR example (port , pin, 1)-> (1U,18U,1);
BUT when i am giving (1U, 0XFFFFFFFFU, 1);[Enable all pins] is not working.
1.)i am giving now the program which was working for single pin
#include <stdio.h>
#include "board.h"
#include "peripherals.h"
#include "pin_mux.h"
#include "clock_config.h"
#include "LPC54628.h"
#include "fsl_debug_console.h"
int main()
{
gpio_pin_config_t led_config = {
kGPIO_DigitalOutput,
0,
};
GPIO_PortInit(GPIO, 1U);
GPIO_PinInit(GPIO, 1U, 18U , &led_config);
GPIO_PinWrite(GPIO, 1U,18U, 0);
return(0);
}
this code is working and output is coming at the port(1), 18th pin.
2.)i am giving now the program which was not working
#include <stdio.h>
#include "board.h"
#include "peripherals.h"
#include "pin_mux.h"
#include "clock_config.h"
#include "LPC54628.h"
#include "fsl_debug_console.h"
int main()
{
gpio_pin_config_t led_config = {
kGPIO_DigitalOutput,
0,
};
GPIO_PortInit(GPIO, 1U);
GPIO_PinInit(GPIO, 1U, 0XFFFFFFFFU , &led_config);
GPIO_PinWrite(GPIO, 1U,0XFFFFFFFFU, 0);
return(0);
}
When i am enabling all pin in a port, it was not working.
this was my issue,please solve it and answer it.
wanted to enable this port pins in a single line