- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I have override UART_RTS pin as GPIO by calling CyU3PDeviceGPIOOverride() API.
which api i need to use to make it this pin as output pin?
if i use this pin as output,can i use uart communication with only uart_tx and uart_rx pin parlally?
let me know
regards,
geetha.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The API CyU3PDeviceGpioOverride allows you to use a GPIO pin without calling CyU3PDeviceConfigureIOMatrix.
After CyU3PDeviceGpioOverride, you need to do the following actions.
status = CyU3PDeviceGpioOverride (22, CyTrue);
if (status != 0)
{
CyU3PDebugPrint (4, "CyU3PDeviceGpioOverride failed, error code = %d\n",
status);
}
/* Configure GPIO 22 as output; Used as Reset for Sensor */
gpioConfig.outValue = CyTrue;
gpioConfig.inputEn = CyFalse;
gpioConfig.driveLowEn = CyTrue;
gpioConfig.driveHighEn = CyTrue;
gpioConfig.intrMode = CY_U3P_GPIO_NO_INTR;
status = CyU3PGpioSetSimpleConfig(22, &gpioConfig);
if (status != CY_U3P_SUCCESS)
{
CyU3PDebugPrint (4, "CyU3PGpioSetSimpleConfig failed, error code = %d\n",
status);
}
The code above configure GPIO 22 as output
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi geetha,
Do you invoke CyU3PDeviceGpioOverride or CyU3PDeviceOverride?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
hello,
its CyU3PDeviceGpioOverride() API
regards,
geetha.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The API CyU3PDeviceGpioOverride allows you to use a GPIO pin without calling CyU3PDeviceConfigureIOMatrix.
After CyU3PDeviceGpioOverride, you need to do the following actions.
status = CyU3PDeviceGpioOverride (22, CyTrue);
if (status != 0)
{
CyU3PDebugPrint (4, "CyU3PDeviceGpioOverride failed, error code = %d\n",
status);
}
/* Configure GPIO 22 as output; Used as Reset for Sensor */
gpioConfig.outValue = CyTrue;
gpioConfig.inputEn = CyFalse;
gpioConfig.driveLowEn = CyTrue;
gpioConfig.driveHighEn = CyTrue;
gpioConfig.intrMode = CY_U3P_GPIO_NO_INTR;
status = CyU3PGpioSetSimpleConfig(22, &gpioConfig);
if (status != CY_U3P_SUCCESS)
{
CyU3PDebugPrint (4, "CyU3PGpioSetSimpleConfig failed, error code = %d\n",
status);
}
The code above configure GPIO 22 as output