Digilent 410-173 User Manual

CCeerreebboott 3322MMXX44™
RReeffeerreennccee MMaannuuaal
Cerebot 32MX4 Circuit Diagram
Revision: August 26, 2011 Note: This document applies to REV C and REV D of the board.
™ BBooaarrdd
l
Overview
The Cerebot 32MX4 board is a useful tool for embedded control and robotics projects for both students and hobbyists.
Its versatile design and programmable microcontroller lets you access numerous peripheral devices and program the board for multiple uses. The board has many I/O connectors and power supply options.
The Cerebot 32MX4 works with the Microchip MPLAB development environment and provides built in programming and debugging support under MPLAB.
The Cerebot 32MX4 provides a number of connections for peripheral devices. It has nine connectors for attaching Digilent Pmod™ peripheral modules. Digilent peripheral modules include H-bridges, analog-to-digital and digital-to-analog converters, speaker amplifier, switches, buttons, LEDs, as well as converters for easy connection to RS232, screw terminals, BNC jacks, servo motors, and more.
Features include:
a PIC32MX460F512L microcontroller
support for programming and
debugging within the Microchip MPLAB development environment
nine Pmod connectors for Digilent peripheral module boards
eight hobby RC servo connectors
USB 2.0 Device, Host, and OTG
support
two push buttons
four LEDs
multiple power supply options, including
USB powered
ESD protection and short circuit protection for all I/O pins.
215 E Main Suite D | Pullman, WA 99163
(509) 334 6306 Voice and Fax
Doc: 502-173 page 1 of 15
Copyright Digilent, Inc. All rights reserved. Other product and company names mentioned may be trademarks of their respective owners.
Cerebot 32MX4 Reference Manual
Features of the PIC32MX460F512L include:
512KB internal program flash memory
32KB internal SRAM memory
USB 2.0 compliant full-speed On-The-
Go (OTG) controller with dedicated DMA channel
two serial peripheral interfaces (SPI)
two UART serial interfaces
two I2C serial interfaces
five 16-bit timer/counters
five timer capture inputs
five compare/PWM outputs
sixteen 10-bit analog inputs
two analog comparators
For more information on the PIC32MX460F512L microcontroller, refer to the PIC32MX3XX/4XX Family Data Sheet and the PIC32 Family Reference Manual available at www.microchip.com.
Functional Description
The Cerebot 32MX4 is designed for embedded control and robotic applications as well as microprocessor experimentation. Firmware suitable for many applications can be downloaded to the Cerebot 32MX4’s programmable PIC32 microcontroller.
The board has a number of connection options, and is specially designed to work with the Digilent line of Pmod peripheral modules with various input and output functions. For more information, see www.digilentinc.com. In addition to the Pmod connectors, the board supports direct connection of up to 8 RC hobby servos, provides two on-board push buttons and four on-board LEDs for user i/o, as well as providing connections for two I2C busses. A serial EEPROM and a serial D/A converter are provided on one of the I2C busses.
The Cerebot 32MX4 can be used with the Microchip MPLAB development environment. In-system-programming and debug of firmware running on the PIC32 part is supported via USB within MPLAB. The in-system-
programming and debug subsystem is implemented in IC5, a PIC18LF4550 microcontroller. Access to this subsystem is accomplished via USB connector J11. Normally, J11 will be connected to an available USB port on a PC while developing firmware to run on the PIC32 microcontroller.
The Cerebot 32MX4 features a flexible power supply routing system with a number of options for powering the board as well as powering peripheral modules connected to the board. It can be USB powered via either the debug USB port or the USB device port, or it can be powered from an external power supply or batteries.
Programming and In-System Debug Using MPLAB
The Cerebot 32MX4 board is intended to be use with the Microchip MPLAB IDE for firmware development, programming and in­system debug. The board is compatible with the Microchip PIC32 Starter Kit board, and appears to MPLAB as a PIC32 Starter Kit. When installing the MPLAB software, ensure that the PIC32MX Starter Kit support is installed.
After the MPLAB software is installed, the first time that the board is used, Windows will need to install the Microchip USB device driver to connect to the board. If the “Found New Hardware Wizard” asks for the installation CD and no CD is available, click OK anyway. In the “Files Needed” dialog box, use the browse button to navigate to the folder: “Program Files\Microchip\MPLAB IDE\PIC32MXSkit\Drivers” and select the file: mp32mxsk.sys and click on OK. The wizard should then complete installing the proper driver for the board. This process may need to be repeated if the board is later connected to a different USB port.
When creating a new project, ensure that the device is set to PIC32MX460F512L. On the Debugger.Select Tool menu, select the PIC32 Starter Kit as the debugger.
www.digilentinc.com page 2 of 15
Copyright Digilent, Inc. All rights reserved. Other product and company names mentioned may be trademarks of their respective owners.
Cerebot 32MX4 Reference Manual
Board Power Supply
The Cerebot 32MX4 may be USB powered via either the USB debug port, or the USB device port. Alternatively, the board may be powered via dedicated, “external”, power supply connectors.
There are three different power supply connectors on Cerebot 32MX4 for connecting an external power supply: J13, J14, and J18.
The barrel connector, J13, is useful for desktop development and testing where using USB or battery power is not suitable. J13 is the connector used by the AC supply adapter optionally available from Digilent, or other sources. J13 is a 2.5mm x 5.5mm coaxial connector wired with the center terminal as the positive voltage.
J14 is a two-pin male header that provides easy battery or battery-pack connection. Digilent has both two-cell and four-cell AA battery holders with two pin connectors available for connection to J14.
J18 is a screw terminal connector for an alternative power supply connection for use with higher current battery packs, bench supplies or other power sources where use of a hard wired power supply is desirable.
The Cerebot 32MX4 is rated for external power from 3.6 to 5 volts DC. Using voltage outside this range could damage the board and connected devices.
Connectors J13, J14, and J18 are wired in parallel and connect to the “External Power” position (center position) on the Power Select jumper block J12. A shorting block should be placed on the “External Power” position of J12 when using this option for board power. Only one of these three power connectors should be used at a time. If multiple power supplies are connected simultaneously, damage to the board or the power supplies may occur.
The output of power select jumper block J12 is wired to one terminal of the power switch, SW1. The other terminal of SW1 connects to the unregulated power bus DBG_VU. The DBG_VU bus provides the input to the voltage regulator powering the in-system-programming and debug subsystem.
The Cerebot 32MX4 has a second screw terminal connector, J5 that supplies power to the servo power bus, VS, to power the RC hobby servo connectors. This allows servos to be powered from a separate power supply than the one powering the electronics on the Cerebot 32MX4. This can be useful when using servos that draw large amounts of power.
Jumper JP1 can be used to connect the Cerebot 32MX4 unregulated power bus VU to the servo power bus, VS. When no shorting block is installed on JP1, the VU and VS busses are separate. When a shorting block is on JP1, the two busses are joined and the VU bus can be powered in any of the previously indicated ways, or from connector J5.
The Cerebot 32MX4 can provide power to any peripheral modules attached to the Pmod connectors and to I2C devices powered from the I2C daisy chain connectors, J2 and J6. Each Pmod connector provides power pins that can be powered by either unregulated voltage, VU, or regulated voltage, VCC, by setting the voltage jumper block to the desired position. The I2C power connectors only provide regulated voltage, VCC.
The PIC32 microcontroller and on-board I/O devices operate at a supply voltage of 3.3V provided by the VCC bus. The regulated voltage on the VCC bus is provided by an on­board voltage regulator. This regulator is capable of providing a maximum of 500mA of current. The PIC32 microcontroller will use approximately 55mA when running at 80MHz. The remaining current is available to provide power to attached Pmod and I2C devices. The regulator is on the bottom of the board, near the power connectors, and will get warm when
www.digilentinc.com page 3 of 15
Copyright Digilent, Inc. All rights reserved. Other product and company names mentioned may be trademarks of their respective owners.
Cerebot 32MX4 Reference Manual
the amount of current being used is close to its limit.
Power Supply Monitor Circuit
The Cerebot 32MX4 microcontroller can measure the power supply voltage on the VU and VS power busses using the provided power supply monitor circuits. This feature is especially useful when using batteries because it allows the microcontroller firmware to determine the charge state of the battery and potentially notify the user when a battery supply is low.
Each power supply monitor circuit is made up of a voltage divider that divides the power bus voltage by four, and a filter capacitor to stabilize the voltage. Jumper JP4 enables the supply monitor circuit for VU power, and jumper JP2 enables the supply monitor circuit for VS power. The analog to digital converter built into the PIC32 microcontroller is used to measure the power supply voltages. ADC channel 8 is used to measure VU and ADC channel 9 is used to measure VS.
USB Operation
The PIC32MX460 microcontroller contains a USB 2.0 Compliant, Full Speed Device and On-The-Go (OTG) controller. This controller provides the following features:
USB full speed host and device support
Low speed host support
USB OTG support
Endpoint buffering anywhere in system
RAM
Integrated DMA to access system RAM and Flash memory.
When operating as a USB device, the Cerebot 32MX4 can be used as a self powered device or as a bus powered device. To operate as a self powered device, an external power supply should be connected to any one of the three external power connectors (J13, J14, or J18) and a shorting block placed on the center, “External Power” position of J12. To operate
as a bus powered device, the shorting block should be placed in the “USB Device Port” position on J12.
Connector J15, on the bottom of the board in the lower right corner is the Device/OTG connector. This is a standard USB micro-AB connector. Connect a cable with a micro-A plug (optionally available from Digilent) from this connector to an available USB port for device operation.
When operating as a USB host, the Cerebot 32MX4 must be externally powered. Connect a regulated 5V power supply to any one of the three external power connectors (J13, J14, or J18) and ensure that the shorting block is in the center, “External Power” position of J12. The power supply used must be a regulated 5V supply. The Cerebot 32MX4 board provides power to the attached USB device when operating as a host, and the USB specification requires the use of a 5V power supply.
Jumper JP6 is used to route power to the host connector being used. Place the shorting block in the “Host” position for use with the standard USB Host Connector, J17. Place the shorting block in the “OTG” position for use with the USB OTG connector, J15.
When operating as a USB host, the PIC32MX460 microcontroller controls application of power to the connected device via the VBUSON control pin. A shorting block must be placed in the “VBUSON” position of J16 to enable this connection. With the shorting block in place, bus power is applied to the device by driving the VBUSON pin high. Power is removed from the device by driving the VBUSON pin low. The VBUSON pin is accessed via bit 3 of the U1OTGCON register.
The VBUSON pin drives the enable input of a TPS2051B Current-Limited Power Distribution Switch to control the USB device power. This switch has over-current detection capability. The over-current output pin can be monitored via the INT2/RE9 pin on the PIC32MX460 microcontroller. Insert a shorting block on JP5 to enable this connection. Details about the
www.digilentinc.com page 4 of 15
Copyright Digilent, Inc. All rights reserved. Other product and company names mentioned may be trademarks of their respective owners.
Cerebot 32MX4 Reference Manual
operation of the TPS2051B can be obtained from the data sheet available at the Texas Instruments web site.
There are reference designs available on the Microchip web site demonstrating both device and host operation of PIC32 microcontrollers. These reference designs are suitable to use for developing USB firmware for the Cerebot 32MX4 board.
Pmod Connectors
The Cerebot 32MX4 has nine Pmod connectors for connecting Digilent Pmod peripheral modules. There are two styles of Pmod connector: six-pin and twelve-pin. Both connectors use standard pin headers with 100mil spaced pins. The six-pin connectors have the pins in a 1x6 configuration, while the twelve-pin connectors use a 2x6 configuration. The six-pin connectors provide four I/O signals, ground and a switchable power connection. The twelve-pin connectors provide eight I/O signals, two power and two ground pins. The twelve-pin connectors have the signals arranged so that one twelve-pin connector is equivalent to two of the six-pin connectors. The power connection is switchable between the regulated 3.3V main board supply and the unregulated input supply.
Digilent Pmod peripheral modules can either be plugged directly into the connectors on the Cerebot 32MX4 or attached via cables. Digilent has a variety of Pmod interconnect cables available.
See the “Connector and Jumper Block Pinout Tables” section below for more information about connecting peripheral modules and other devices to the Cerebot 32MX4. These tables indicate the mapping between pins on the PIC32MX460 microcontroller and the pins on the various connectors.
RC Servo Connectors
The Cerebot 32MX4 provides eight 3-pin RC hobby servo connectors for direct control of
servos in robotics and embedded hardware actuator applications. The connectors share I/O pins with Pmod connector JC. Individual I/O pins may be accessed through the JC connector if they're not in use by a servo. Refer to the PIC32 family data sheet for information on how to access the I/O pins.
RC Servos use a pulse width modulated signal, PWM, to control the servo position. The 16-bit timers in the PIC32 microcontroller have the ability to generate PWM signals using the output compare registers. However, it is also possible to use timer interrupts to accomplish this same thing. Using timer interrupts allows a single timer (ideally timer 0) to be used to control the signal timing for all eight servo connectors.
The servo connectors on the Cerebot 32MX4 board are intended to be driven using timer interrupts rather than directly by the pulse width modulators in the internal timers. This frees the pulse width modulators for other uses, such as DC motor speed control. Digilent has a reference design available that illustrates using timer interrupts to control signal timing for the PWM signals to control RC servos.
There are three power options for servo connections: a common power bus (VU) for the Cerebot 32MX4 and servos; separate on-board power busses for the Cerebot 32MX4 (VU) and the servos (VS); or an on-board power bus for the Cerebot 32MX4 (VU) an external power bus for servos.
For the first case above: Install the shorting block on JP1 to connect the VS servo power bus to the VU power bus. The servo power bus is then powered from the same source as the VU power bus. Powering a large number of servos from USB power is not recommended. USB power (J12 in the USB Device Port, or USB Debug Port positions) should only be used to power a couple of servos to avoid exceeding the 500mA that a USB device is allowed to use.
For the second case above: Remove the shorting block from jumper JP2 to make the VS
www.digilentinc.com page 5 of 15
Copyright Digilent, Inc. All rights reserved. Other product and company names mentioned may be trademarks of their respective owners.
Loading...
+ 10 hidden pages