Basic HTML Version

|  | Table of Contents |  | View Full Version

Page 126 - Toucpad robotics C11
P. 126

    Uses in Robotics
                      Sensor Integration: Very popular for connecting multiple sensors (like accelerometers, gyroscopes, magnetometers,
                  u
                      pressure sensors, temperature sensors) to a single microcontroller, reducing wiring complexity.
                      Real-time Clocks and Memory: Interfacing with Real-time Clock (RTC) modules or Electrically Erasable Programmable
                  u
                      Read-Only Memory (EEPROM) chips for data storage.
                      Small Displays: Controlling small Liquid Crystal Displays (LCDs) or Organic Light Emitting Diode (OLED) displays.
                  u
                      Motor Driver Control: Some motor drivers can be controlled via I2C for setting speed or direction.
                  u
                  Speed and Performance

                      Moderate Speed: Faster than UART but generally slower than SPI. Standard speeds range from 100 kilobits per
                  u
                      second (kbps) (Standard Mode) to 400 kbps (Fast Mode), with faster modes like 1 Megabit per second (Mbps)
                      (Fast Mode Plus) and 3.4 Mbps (High-Speed Mode) available.
                      Overhead: The addressing and acknowledgement overhead can reduce the effective data throughput.
                  u
                  Error Detection and Reliability
                      Acknowledgement Bit: The acknowledgement mechanism provides a basic form of error detection, confirming if a
                  u
                      byte was received.
                      No Cyclic Redundancy Check (CRC): Does not include more robust error detection like a Cyclic Redundancy Check,
                  u
                      meaning some data corruption might go undetected.
                      Bus Arbitration: In multi-master systems, a mechanism called “arbitration” ensures that only one master transmits
                  u
                      at a time, preventing data collisions.
                      Reliability: Generally reliable for short-distance communication within a circuit board or between closely located
                  u
                      components.

                  Serial Peripheral Interface (SPI)
                  Description
                  Serial Peripheral Interface, often called SPI, is a synchronous serial communication protocol primarily used for high-speed
                  data transfer over short distances, typically between a microcontroller (master) and one or more peripheral devices
                  (slaves).

                  Key Characteristics and Differences
                      Synchronous: Uses a shared clock line for synchronization.
                  u
                      Four Wires: Typically uses four dedicated wires, allowing full-duplex communication:
                  u
                  	   ∑  Master Out Slave In (MOSI): Data from master to slave.
                  	   ∑  Master In Slave Out (MISO): Data from slave to master.
                  	   ∑  Serial Clock (SCK or SCLK): Clock signal generated by the master.

                  	   ∑  Slave Select (SS or CS - Chip Select): A separate line for each slave. The master pulls this line low to enable
                        (select) a specific slave it wants to communicate with.

                      Master-Slave Architecture: One master device controls communication with one or more slave devices. Each slave
                  u
                      requires its own dedicated Slave Select line.
                      Full-Duplex: Allows simultaneous bidirectional communication (sending and receiving data at the same time).
                  u
                      No Addressing: Unlike I2C, SPI does not use device addresses. Instead, the master selects a slave by activating its
                  u
                      dedicated Slave Select line.
                      Continuous Data Streaming: Can send continuous streams of data without needing start/stop conditions for each
                  u
                      byte, making it very efficient for large data transfers.

                  124
                  Touchpad Robotics - XI

| 121 122 123 124 125 126 127 128 129 130 131 |