Answer
Jan 14, 2025 - 09:48 PM
To connect and use the JOY-IT COM-TTL-RS485 Single Board Converter with an Arduino or Raspberry Pi, please follow the instructions provided in the manual.
For Arduino:
1. Connect the A+ pin of the converter to the A pin of your RS485 end device, and connect the B- pin of the converter to the B pin of your RS485 end device.
2. Use the Arduino IDE to write your code. Make sure to select the correct Port and Board under Tools.
3. Copy the code example provided in the manual and click on Upload to upload the code to your Arduino.
4. Open the serial monitor in the Arduino IDE to see the output.
5. To communicate with your Arduino via a terminal program such as HTerm, set the baud rate to the same speed as your Arduino (e.g., 9600). The data received from the Arduino will be displayed on the serial monitor.
For Raspberry Pi:
1. Enable the serial communication of the Raspberry Pi by running the command "sudo raspi-config" in the terminal.
2. In the configuration menu, go to "3 Interface Options" and select "P6 Serial Port". Negate the question about a login shell being accessible via serial.
3. Restart your Raspberry Pi to apply the changes.
4. Make sure the serial library is installed on your Raspberry Pi by running the command "sudo apt-get install python-serial" in the terminal.
5. Connect the A+ pin of the converter to the A pin of your RS485 end device, and connect the B- pin of the converter to the B pin of your RS485 end device.
6. Create a file named "ttlToRS485.py" using the command "nano ttlToRS485.py" in the terminal.
7. Copy the code example provided in the manual and paste it into the "ttlToRS485.py" file.
8. Execute the script with the command "python3 ttlToRS485.py" in the terminal.
9. To communicate with your Raspberry Pi via a terminal program such as HTerm, set the baud rate to the same speed as in your Python code (e.g., 9600). The data received from the Raspberry Pi will be displayed in the console.
For any further questions or problems, you can contact JOY-IT support via email, telephone, or their ticket support system. Their contact information can be found in the manual or on their website.
Add New Comment