def enable_rx():
    cr1 = stm.mem16[stm.USART6 + stm.USART_CR1]
    cr1 |= 0x04
    stm.mem16[stm.USART6 + stm.USART_CR1] = cr1
Set the RE bit in the CR1 register.
dataset/ETHPy150Open dhylands/upy-examples/bioloid.py/enable_rx