View Single Post
  #3   Spotlight this post!  
Unread 05-04-2016, 18:25
Tyguy56 Tyguy56 is offline
Registered User
FTC #3385
 
Join Date: Feb 2013
Location: Minnesota
Posts: 6
Tyguy56 is on a distinguished road
Re: Serial Port Communication

Quote:
Originally Posted by techhelpbb View Post
Couple of thoughts:

1. Are you able to decode UTF-8 correctly and why not use ASCII?
2. Stop bits? Data bits? Flow control?
3. How are you deriving your clock for the serial on the Arduino?
4. Which equipment is setup for DTE and which DCE?

Know nothing about serial hides the Trellis modems under the couch.
1. If we encode it or not it still returns garbage ascii characters
2. stopbits 1
3. The hardware it setup with only Tx, Rx, and Gnd. Does the Rio have the other lines? Do you know if Arduino has the other lines as well?

our setup is the serial port on the tegra into the arduino using the tx rx and gnd from there a usb cable into a computer with putty to monitor the com port

simple serial code (python)

Code:
    import serial
    ser = serial.Serial(
        port='/dev/ttyS0',
        baudrate = 115200,
        parity=serial.PARITY_NONE
        stopbits=serial.STOPBITS_ONE,
        bytesize=serial.EIGHTBITS
        )
    if(ser.isOpen()):
        ser.close()
    ser.open()
    ser.write('hello'.encode('utf-8'))
Reply With Quote