Microchip
直播中

杨嘉怡

7年用户 232经验值
私信 关注
[问答]

RN4678硬件流量控制不当行为?

RN467 8模块。设备固件VER 1.00 .5。蓝牙经典被启用,BLE在模块上被禁用。启用了HaveWaveFlug控件(默认特征集,0x1000)。但是在一个模块上,当接收到一个字节时,模块的P0YRRTS(PIN 17)流量控制输出。期望的数据流:PC APP --- & GT;蓝牙:&,RN468--- &串行端口TX----GT;MCU接收RealestPC APP & lt;---蓝牙RT;--- RN467 8& LT;---串行端口RX-LT;MCU SEN。DS响应是这样的,在一个范围内观察到,并用PC终端程序:上电模块。RN467的RTS输出很低。从PC发送1字节…它在MCU接收。MCU用多个字节响应…收到PCRT仍然是低发送2字节从PC…在MCU,MCU开始响应。模块RTS输出在第一字节的起始位的下降沿之后上升。这防止MCU继续发送字节。RTS保持断言(高)直到功率循环。这里发生了什么?

以上来自于百度翻译


      以下为原文

    RN4678 module. Device firmware ver 1.00.5. Bluetooth Classic is enabled and BLE is disabled on the module.
Hardware flow control is enabled (default feature set, 0x1000).

Several modules I tested worked as expected. But on one module, the P00_RTS (pin 17) flow control output of the module asserts when a single byte is received.

Desired data flow:
PC app --->  Bluetooth ---> RN4678 ---> serial port TX ---> MCU receives request
PC app <---  Bluetooth <--- RN4678 <--- serial port RX <--- MCU sends response

This is what happens, observed on a scope and with a PC terminal program:
Power up module.
RTS output from RN4678 is low.

Send 1 byte from PC ... it is received at MCU.
MCU responds with multiple bytes ... received at PC
RTS is still low

Send 2 bytes from PC ... they are received at MCU.
MCU begins to respond.
Module RTS output rises just after the falling edge of the start bit of the first byte.
This prevents the MCU from continuing to send bytes.
RTS remains asserted (high) until a power cycle.

What is happening here?

回帖(3)

寇亦青

2018-12-6 15:22:24
将特征集位图设置为0x1000(启用UART的HW流量控制)。我尝试禁用流控制(位图=0x000)。这样,没有一个字节通过。将它变为启用HW流量控制(位图=0x1000)。问题如上所述返回。

以上来自于百度翻译


      以下为原文

    The feature set bitmap is set to 0x1000 (HW flow control for UART is enabled).
I tried disabling the flow control (bitmap=0x0000). With that, not a single byte passes through.
Changed it back to HW flow control enabled (bitmap=0x1000). The problem returns as described above.
举报

寇亦青

2018-12-6 15:39:24
当CTS流量控制被断言时,引脚30 LED输出变高并保持高电平,使LED断开。就在这之前,随着一个端口打开,LED显示闪烁闪烁模式。

以上来自于百度翻译


      以下为原文

    When the CTS flow control is asserted, pin 30 LED output goes high and stays high, turning the LED off. Just before this, with a port open, the LED showed the blink-blink pattern.
举报

寇亦青

2018-12-6 15:46:04
解决:我在错误的时间发送重置脉冲。RESET强制RTS握手输出声明。

以上来自于百度翻译


      以下为原文

    SOLVED:
I was sending a reset pulse at the wrong time. Reset was forcing the RTS handshaking output to assert.
举报

更多回帖

发帖
×
20
完善资料,
赚取积分