Classes - Beard

You are here: start » robot_soccer » 2017 » motion_control


|

Meta

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
robot_soccer:2017:motion_control [2017/01/30 19:51]
supersolver [H-Bridge]
robot_soccer:2017:motion_control [2017/02/18 14:14]
supersolver [Raspberry Pi Serial Communication]
Line 52: Line 52:
   * GPIO pins 14 and 15 (physical pins 8 and 10) are the tx and rx pins on the Raspberry Pi. See [[https://​www.raspberrypi.org/​documentation/​usage/​gpio-plus-and-raspi2/​|Raspberry Pi GPIO]] and this [[http://​pinout.xyz/#​|Interactive Pinout Diagram]]. ​   * GPIO pins 14 and 15 (physical pins 8 and 10) are the tx and rx pins on the Raspberry Pi. See [[https://​www.raspberrypi.org/​documentation/​usage/​gpio-plus-and-raspi2/​|Raspberry Pi GPIO]] and this [[http://​pinout.xyz/#​|Interactive Pinout Diagram]]. ​
   * By default the serial port /dev/ttyS0 is connected to these pins. Unfortunately,​ the baud rate of /dev/ttyS0 is derived from a dynamic system clock (slows down to save power), and thus is completely useless. However, if you disable bluetooth by adding the line dtoverlay=pi3-disable-bt to the end /​boot/​config.txt,​ the serial port ttyAMA0 (which is normally used for bluetooth) will be rerouted to the serial pins (8 and 10), thus fixing the clock problem. For more information see http://​raspberrypi.stackexchange.com/​a/​56178   * By default the serial port /dev/ttyS0 is connected to these pins. Unfortunately,​ the baud rate of /dev/ttyS0 is derived from a dynamic system clock (slows down to save power), and thus is completely useless. However, if you disable bluetooth by adding the line dtoverlay=pi3-disable-bt to the end /​boot/​config.txt,​ the serial port ttyAMA0 (which is normally used for bluetooth) will be rerouted to the serial pins (8 and 10), thus fixing the clock problem. For more information see http://​raspberrypi.stackexchange.com/​a/​56178
 +  * You'll need to add your user to the dialout group and logout or restart to be able to have permissions to access the serial port. Don't simply run python with sudo or you'll have problems later on when you try to run ROS stuff. See [[http://​askubuntu.com/​questions/​112568|How to add a user to the dialout group]]
   * To connect the PSoC directly to the Raspberry Pi you will need to snap off the programmer. To ensure a clean break, press the PSoC gently against the edge of a table or hard surface.   * To connect the PSoC directly to the Raspberry Pi you will need to snap off the programmer. To ensure a clean break, press the PSoC gently against the edge of a table or hard surface.
   * If you would rather communicate using the USB and avoid snapping off the programmer, you will need to download the [[http://​www.cypress.com/​products/​usb-serial-bridge-controller|USB serial bridge controller]] drivers. You will need to compile the drivers using make. I have not yet tried it.   * If you would rather communicate using the USB and avoid snapping off the programmer, you will need to download the [[http://​www.cypress.com/​products/​usb-serial-bridge-controller|USB serial bridge controller]] drivers. You will need to compile the drivers using make. I have not yet tried it.