I want to communicate with my samsung s4 serially. and I need to use the wire. This is for a testing purpose and my final aim is to communicate directly with my arduino. Before that I wanted do this. Thank you in advance.
You can use the library USB Serial for communication directly from your android phone to the audino using the OTG Cable.Below is the link for usbserial and sample code.