I am trying to send and receive a response from a machine using Modbus (TTL to Rs485) and nrf51822.
Connections: R0 -> RX(P0.11) ,D1->TX(p0.09), RE&DE->P0.19,VCC->5V
Just the same as to connect with Arduino (Have implemented with Arduino mega)
I am using Keil for programming and trying to send and receive in hexadecimal format, but I am not sure if even command is transmitted and obviously I am not getting any response.
I am not sure about connections also. Attaching code.
Please let me know where I am wrong.