I'm using processor expert and the sdk fsl_gpio for my frdm-kl43z. The commands gpio_drv_setpinoutput, gpio_drv_writepinoutput and gpio_drv_clearpinoutput, all are not working.
I've gotten gpio_drv_togglepinoutput to work, but these other functions have not worked. I've done 10 or so projects and just have had to suffer without the use of these commands.
Any ideas?
Thanks,
Chris
Solved! Go to Solution.
Hi Chris,
I just tested the following code using KDS_3.0+KSDK_1.3+PE for frdm-kl43z successfully.
/* Write your code here */
/* For example: for(;;) { } */
uint32_t pinstate;
while(1) {
pinstate = GPIO_DRV_ReadPinInput(LED2_RED);
pinstate = !pinstate;
GPIO_DRV_WritePinOutput(LED2_RED, pinstate);
pinstate = GPIO_DRV_ReadPinInput(LED2_RED);
GPIO_DRV_SetPinOutput(LED2_RED);
pinstate = GPIO_DRV_ReadPinInput(LED2_RED);
GPIO_DRV_ClearPinOutput(LED2_RED);
pinstate = GPIO_DRV_ReadPinInput(LED2_RED);
GPIO_DRV_TogglePinOutput(LED2_RED);
}
Is your KDS Help->Install new software.... up-to-date?
Attached is my working project.
Regards,
David
Hi Chris,
I just tested the following code using KDS_3.0+KSDK_1.3+PE for frdm-kl43z successfully.
/* Write your code here */
/* For example: for(;;) { } */
uint32_t pinstate;
while(1) {
pinstate = GPIO_DRV_ReadPinInput(LED2_RED);
pinstate = !pinstate;
GPIO_DRV_WritePinOutput(LED2_RED, pinstate);
pinstate = GPIO_DRV_ReadPinInput(LED2_RED);
GPIO_DRV_SetPinOutput(LED2_RED);
pinstate = GPIO_DRV_ReadPinInput(LED2_RED);
GPIO_DRV_ClearPinOutput(LED2_RED);
pinstate = GPIO_DRV_ReadPinInput(LED2_RED);
GPIO_DRV_TogglePinOutput(LED2_RED);
}
Is your KDS Help->Install new software.... up-to-date?
Attached is my working project.
Regards,
David
Hi,
Everything is up to date, but the functions other than toggle do not work.
Actually it's working now