RasPi-GVS

From blwiki
Jump to: navigation, search

Tindie-mediums.png

Board Design

Like a lot of folks we got excited when the Raspberry Pi was first announced. We couldn't wait to get our hands on our first board. When our chance came to get a Pi we also bought a prototyping board so we could connect up our own devices to the Pi. We anxiously awaited the arrival of our card. It felt like our card would never arrive.

While we were waiting, we dug deeper and found out that Raspberry is limited to 3.3V I/O and we realized that the GVS devices we already have for our Arduinos are 5V parts that would not work with our Raspberry Pi. Sure we could adapt one of the 3.3V to 5V converters out there but that sounded like a lot of work. What we really wanted was a way to allow our 5V GVS parts to connect to the Raspberry Pi without a lot of hand wiring but we couldn't find a card out there that does the 3.3V to 5V voltage conversion that our 5V parts need.

So we designed a card to meet our needs, the Raspberry Pi-GVS Card.

RasPi-GVS-X3-CCA-640px-01.jpg

The RasPi-GVS card is modeled on the Arduino Sensor Shields, also known as GVS shields. Arduino Sensor Shields bring out the pins of the Arduino to GVS (set of Ground, Voltage and Signal) pins. Unfortunately, the Raspberry Pi can't work with the same 5V GVS devices as the Arduino since the Raspberry Pi has 3.3V I/O.

The RasPi-GVS card allows the Raspberry Pi to communicate with the same 5V sensors by performing voltage translation from the 3.3V of the Raspberry Pi to 5V.

Features

  • 3.3V to 5V bidirectional voltage translators on Raspberry Pi GPIO lines
  • (7) 5V GPIO lines on GVS connectors
  • (2) 5V SPI interfaces (can be used as 5 GPIO lines)
  • (1) 5V UART interface
  • (1) 5V I2C interface (can be used as 2 GPIO lines)
  • GPIO_4 enables/disables the voltage translators (active high)
  • Power Supply which can optionally power the GVS connectors
  • 49x49mm card form factor

Voltage Translators

The Raspi-GVS board uses Texas Instrument TXS0108 voltage translators.

Voltage Translators Features

  • No Direction-Control Signal Needed
  • Max Data Rates
    • 60 Mbps (Push Pull)
    • 2 Mbps (Open Drain)
  • 1.2 V to 3.6 V on A Port and 1.65 V to 5.5 V on
  • B Port (VCCA ≤ VCCB)
  • No Power-Supply Sequencing Required –
    • Either VCCA or VCCB Can Be Ramped First
  • Latch-Up Performance Exceeds 100 mA Per JESD 78, Class II
  • ESD Protection Exceeds JESD 22 (A Port)
    • 2000-V Human-Body Model (A114-B)
    • 150-V Machine Model (A115-A)
    • 1000-V Charged-Device Model (C101)
  • IEC 61000-4-2 ESD (B Port)
    • ±6-kV Air-Gap Discharge
    • ±8-kV Contact Discharge

Voltage Translators Architecture

Datasheet

The TXS0108E can be used in level-translation applications for interfacing devices or systems operating at different interface voltages with one another. The TXS0108E is ideal for use in applications where an open-drain driver is connected to the data I/Os. The TXS0108E can also be used in applications where a push-pull driver is connected to the data I/Os, but the TXB0104 might be a better option for such push-pull applications. The TXS0108E device is a semi-buffered auto-direction-sensing voltage translator design is optimized for translation applications (e.g. MMC Card Interfaces) that require the system to start out in a low-speed open-drain mode and then switch to a higher speed push-pull mode.

TXS0108Arch.PNG

To address these application requirements, a semi-buffered architecture design is used and is illustrated above (see Figure 1). Edge-rate accelerator circuitry (for both the high-to-low and low-to-high edges), a High-Ron n-channel pass-gate transistor (on the order of 300 Ω to 500 Ω) and pull-up resistors (to provide DC-bias and drive capabilities) are included to realize this solution. A direction-control signal (to control the direction of data flow from A to B or from B to A) is not needed. The resulting implementation supports both low-speed open-drain operation as well as high-speed push-pull operation.

When transmitting data from A to B ports, during a rising edge the One-Shot (OS3) turns on the PMOS transistor (P2) for a short-duration and this speeds up the low-to-high transition. Similarly, during a falling edge, when transmitting data from A to B, the One-Shot (OS4) turns on NMOS transistor (N2) for a short-duration and this speeds up the high-to-low transition. The B-port edge-rate accelerator consists of one-shots OS3 and OS4, Transistors P2 and N2 and serves to rapidly force the B port high or low when a corresponding transition is detected on the A port.

When transmitting data from B to A ports, during a rising edge the One-Shot (OS1) turns on the PMOS transistor (P1) for a short-duration and this speeds up the low-to-high transition. Similarly, during a falling edge, when transmitting data from B to A, the One-Shot (OS2) turns on NMOS transistor (N1) for a short-duration and this speeds up the high-to-low transition. The A-port edge-rate accelerator consists of one-shots OS1 and OS2, Transistors P1 and N1 components and form the edge-rate accelerator and serves to rapidly force the A port high or low when a corresponding transition is detected on the B port.

Power Supply

The RaspPi-GVS offers flexible power supply options. The 5V for the GVS Connnectors and translators can come either from the Raspberry Pi or from the 5V power supply on the RaspPi-GVS.

A three pin header and jumpers are used to select the voltage source(s). Installing a single jumper from pins 2 to 3 allow the Raspberry Pi to power the GVC connectors and voltage translators. Installing a jumper from 1 to 2 powers the GVS connections and voltage translators from the 5V power supply.

Connectors

P1 - Raspberry Pi GPIO Connector

Raspberry Pi Connector

RasPi-GPIOs.png

J1 - I2C bus

  1. GND
  2. 5V
  3. SDA=GPIO2
  4. SCL=GPIO3

J2 - UART I/F

  1. GND
  2. 5V
  3. Tx=GPIO14
  4. Rx=GPIO15

J3 - IO_18 GVS

  1. GND
  2. 5V
  3. GPIO_18

J4 - IO_17 GVS

  1. GND
  2. 5V
  3. GPIO_17

J5 - IO_27 GVS

  1. GND
  2. 5V
  3. GPIO_27

J6 - IO_23 GVS

  1. GND
  2. 5V
  3. GPIO_23

J7 - IO_22 GVS

  1. GND
  2. 5V
  3. GPIO_22

J8 - IO_24 GVS

  1. GND
  2. 5V
  3. GPIO_24

J9 - IO_25 GVS

  1. GND
  2. 5V
  3. GPIO_25

J10 - SPI0 (Serial Peripheral Interface)

  1. GND
  2. 5V
  3. MOSI (GPIO_10)
  4. MISO (GPIO_9)
  5. SCK (GPIO_11)
  6. CE0 (GPIO_8)

J11 - SPI1 (Serial Peripheral Interface)

  1. GND
  2. 5V
  3. MOSI (GPIO_10)
  4. MISO (GPIO_9)
  5. SCK (GPIO_11)
  6. CE1 (GPIO_7)

DC Power 7-9 VDC

  1. Shell - Ground
  2. Center - Power (7-9 VDC)

J13 - Power Select

  • 1-2 = Power GVS and voltage translators from the voltage regulator on the RasPi-GVS
  • 2-3 = Power GVS and voltage translators from the Raspberry Pi

Parts List / Assembly Sheet

RasPi-GVS Assembly Sheet

Qty Value RefDes Footprint
4 0.1uF C3,C4,C5,C6 SM0805
1 FUSE F2 SM1206
2 TXS0108 U1,U2 SOG20
6 CONN_3 J3,J4,J5,J6,J7,J8,J9 PIN_ARRAY_3X1
2 CONN_4 J1,J2 PIN_ARRAY_4x1
2 CONN_6 J10,J11 PIN_ARRAY-6X1
1 RASPIO P1 pin_array_13x2

If No DC Power


Qty Value RefDes Footprint
1 CONN_3 Jumper J13 from 2-3

If DC Power

Qty Value RefDes Footprint
1 0.1uF C2 SM0805
1 1uF C1 SM1206
1 FUSE F1 SM1206
1 AP1117 U3 SOT223
1 JACK-3.5MM J12 JACK_2.1MM
1 CONN_3 J13 PIN_ARRAY_3X1

Factory Tests

Equipment

  • Unit Under Test (UUT)
  • LED-Test-2 card
  • Raspberry Pi Model B (not B Plus)
  • GVS Cabling

GPIO Tests

  • Connect D1 through... to J3-J9
  • Connect ...
  • Run
cd RasPi/RasPi-GVS/
sudo python pyGVS.py
 
  • LEDs should cycle

UART Tests

Setup - Run first use only

sudo cp /boot/cmdline.txt /boot/cmdline_backup.txt
sudo nano /boot/cmdline.txt
  • Originally it contained:
dwc_otg.lpm_enable=0 console=ttyAMA0,115200 console=tty1 root=/dev/mmcblk0p6 roo
tfstype=ext4 elevator=deadline rootwait
  • Delete the parameter involving the serial port (ttyAMA0) to get the following:
dwc_otg.lpm_enable=0 console=tty1 root=/dev/mmcblk0p6 roo
tfstype=ext4 elevator=deadline rootwait
  • Edit
cd /etc
sudo nano /etc/inittab
  • Comment out the following line:
T0:23:respawn:/sbin/getty -L ttyAMA0 115200 vt100
  • Install minicom
sudo apt-get install minicom
  • Reboot

Run every time

  • Run minicom
minicom -b 115200 -o -D /dev/ttyAMA0
  • Type - get nothing
  • Jumper J2-3 to J2-4 UART tx/rx
  • Type - get back what you type

Rev X3 Board

Rev X2 Board

  • Ordered from OshPark

RasPi-GVS-Front-OshPark-X2.png

Rev X1 Board

  • Rev X1 board works.

RasPi-front.png