This is sending code
ENUM_DEVICE_ERROR PAL_RS485WriteByte (struct dal_port_type * type, uint8 byte)
{
Uint32 index;
DelayTime=RS485_Send_Delay_Count;
OSSchedLock ();
RS485_Send_En;
while (! (UART4 - & gt; The SR & amp; USART_FLAG_TXE));
UART4 - & gt; DR=(byte & amp; (uint16_t) 0 x01ff);
For (index=0; The index & lt; DelayTime; Index++);
RS485_Rev_En;
OSSchedUnlock ();
Return DEVICE_OK;
}
In the While loop has not gone
CodePudding user response:
CodePudding user response:
This place is correct?CodePudding user response:
STM32 serial port communication there is a place to note that no validation is 8 bits of data, parity is nine, estimation is you made a mistake hereCodePudding user response:
"Now you need to set up for parity"In fact you have odd parity!!