USB EZ-PD™ Type-C Forum Discussions
Hi,
I'm trying to read analog voltage level at pin #24 (P2.4) but I get a wrong value. Here is my code.
gpio_hsiom_set_config(GPIO_PORT_2_PIN_4, HSIOM_MODE_AMUXB, GPIO_DM_HIZ_ANALOG, 0);
CyDelayUs(200);
pd_adc_calibrate(TYPEC_PORT_0_IDX, PD_ADC_ID_1);
uint8_t level = pd_adc_sample(TYPEC_PORT_0_IDX, PD_ADC_ID_1, PD_ADC_INPUT_AMUX_B);
hsiom_set_config(GPIO_PORT_2_PIN_4, HSIOM_MODE_GPIO);
ADC return value from pd_adc_sample() is very low, only 2-5. Actual voltage on the pin is 1.1V. The return value is 0 if voltage in pin is 0V so there seems to be a connection.
However if I use HSIOM_MODE_AMUXA & PD_ADC_INPUT_AMUX_A instead I do get the expected value (~85) but then PD immediately raises app events APP_EVT_RP_CHANGE and APP_EVT_VBUS_OVP_FAULT. I assume this is because port uses AMUXA to sense the VBUS.
How do I read the pin voltage level correctly with MUXB?
What is the meaning of suffix A of this MPN: CYPD6229-52LQXIA ?
我们在开发CCG5的时候遇到一个问题,请求各位帮助。
问题是这样的:
我们的CCG5定义了一个I2C master,需要与外部IC通信。我们不确定I2C读写操作相关代码应该放在哪里执行?
1、我们放在main函数中执行,虽然I2C读写操作成功了。但导致TYPE-C口的PD协商失败了。
2、我们放在app_event_handler的APP_EVT_PD_CONTRACT_NEGOTIATION_COMPLETE事件中执行,I2C读写失败了。
Show Less请教个问题,怎么在CCG5中的UART的RX获取外部发来的数据?
我启用了internal interrupt,然后在代码中添加了如下code:
void uart_debug_rx_isr(void){
G20_origin_led_Write(a);
}
UART_DEBUG_Start();
UART_DEBUG_EnableInt();
UART_DEBUG_SetCustomInterruptHandler(uart_debug_rx_isr);
不仅G20_origin_led_Write(a);没有起作用,串口还会crash。
Show Less
Could you provide the DSN file and reference desgin for CCG7,CCG8,PMG1-S3 ?
Hi,
We have a project that was created by ModusToolbox and is based on the MCU (CYPM1322-97BZXIT).
This project is already in production.
Now, we want to have hardware changes and transfer this project to another MCU (CYPM1311-48LQXI).
How can we perform this transfer?
Thanks
Ryan Chu
Show Less