Hello Aykut,
How do you know it doesn't work ?
I haven't LPC1517, while I test on LPC1549, it can work well.
After I configure the PIO0_20 to GPIO, can't debug project . I measure the PIO0_20 pin, it works well as my
code. On my code, toggle this pin in a timer interrupt, the PIO0_20 can out put low - high - low -high... as GPIO.
#define PORT_MASK ((1 << 0) | (1 << 1) | (1 << 24)|(1<<20))
void SysTick_Handler(void)
{
uint32_t states;
/* Get current masked port states */
states = Chip_GPIO_GetMaskedPortValue(LPC_GPIO, 0);
/* Toggle all the states */
states = ~states;
/* Write states back via masked set function. Only the enanled
(masked states) will be changed. */
Chip_GPIO_SetMaskedPortValue(LPC_GPIO, 0, states);
}
#define PINENABLE1_VAL ((1<<13)|(1<<23))
In main()
{
...
Chip_Clock_EnablePeriphClock(SYSCTL_CLOCK_SWM);
LPC_SWM->PINENABLE[1] |= PINENABLE1_VAL;
...
}
I configure the code based on "periph_gpio" demo under LPCopen.
I also checked your board_sysinit.c file , it seem there is no error, just disable the SWDIO pin two times:

Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------