Robotic System Control Board ...................................................................................................................................... 1
So what in the world does “RCAT™”mean? .................................................................................................................. 5
What are we trying to do that other boards cannot? .................................................................................................... 6
Power System .............................................................................................................................................................. 8
Major Subsystems .......................................................................................................................................................... 10
LED ............................................................................................................................................................................ 16
Control ................................................................................................................................................................... 16
System Clock .............................................................................................................................................................. 17
1M-bit serial EEPROM ................................................................................................................................................ 19
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Alternatives for controlling the mosfets ................................................................................................................. 24
Direct I/O Access ........................................................................................................................................................ 25
USART 2 Port – J14 and J7 ...................................................................................................................................... 27
3.3 Volt Input/Output ............................................................................................................................................. 28
USART 3 Port – J8 ................................................................................................................................................... 30
Final comments about USART direct connections ....................................................................................................... 34
Summary of direct access ports .................................................................................................................................. 34
USARTS, and Serial Communications Interfaces ............................................................................................................. 35
Ethernet System ............................................................................................................................................................ 41
Programming IDE (interactive Development Environment) ........................................................................................ 43
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Warranties
1. (a) Robot Circuits, LLC warrants for a period of one (1) year from the date of sale that the RCAT™ Control Board conforms to and will
perform according to the Specifications.
(b) Robot Circuits, LLC shall not be liable for any defects caused by abuse, neglect, improper use, installation, or modification of the
RCAT™, nor as a result of any customer design or use involving the attachment of any devices, testing apparatus, or other hardware.
(c) Robot Circuits, LLC shall not be liable for any damage or harm, bodily or other, resulting from specifications, designs documentation,
or instructions, verbal or written, not produced by Robot Circuits, LLC.
2. If the RCAT™ Control Board fails to perform to the warranty set forth in section 1 above, then Robot Circuits’ sole liability shall be to
effect the replacement of the board. Replacement board shall be covered under the warranty for the full warranty period.
3. THIS LIMITED WARRANTY IS THE END-USER’S SOLE AND EXCLUSIVE REMEDY AGAINST ROBOT CIRCUITS, LLC WHERE PERMITTED BY LAW.
AND SUBJECT TO SECTION (8). EXCEPT AS SET FORTH ABOVE, PRODUCTS ARE PROVIDED “AS IS” AND “WITH ALL FAULTS”. ROBOT
CIRCUITS, LLC DISCLAIMS ALL OTHER WARRANTIES, EXPRESS OR IMPLIED, REGARDING PRODUCTS, INCLUDING, BUT NOT LIMITED TO,
ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
4. The Customer agrees that prior to using any systems that include Robot Circuits, LLC products, the Customer will test such systems and
the functionality of the products as used in such systems. Robot Circuits, LLC may provide technical, applications or design advice, quality
characterization, reliability data or other services. The Customer acknowledges and agrees that providing these services shall not expand
or otherwise alter Robot Circuits, LLC’s warranties, as set forth above, and that no additional obligations or liabilities shall arise from
Robot Circuits, LLC providing such services.
5. Robot Circuits, LLC products are not authorized for use in safety-critical applications where a failure of the Robot Circuits, LLC product
would reasonably be expected to cause severe personal injury or death. Safety-critical applications include, without limitation, life
support devices and systems, equipment or systems for the operation of nuclear facilities and weapons systems. Robot Circuits, LLC
products are neither designed nor intended for use in military or aerospace applications or environments, nor for automotive
applications or the automotive environment. The Customer acknowledges and agrees that any such use of Robot Circuits, LLC products is
solely at the Customer’s risk, and that the Customer is solely responsible for compliance with all legal and regulatory requirements in
connection with such use.
6. The Customer acknowledges and agrees that the Customer is solely responsible for compliance with all legal, regulatory and safety-
related requirements concerning the products and any use of Robot Circuits, LLC products in the Customer’s applications, not-withstanding any applications-related information or support that may be provided by Robot Circuits, LLC.
7. In no event shall Robot Circuits, LLC be liable to the Customer or any third parties for any special, collateral, indirect, punitive, incidental,
consequential or exemplary damages in connection with or arising out of the products provided hereunder, regardless of whether Robot
Circuits, LLC has been advised of the possibility of such damages. This section will survive the termination of the warranty period.
8. Robot Circuits, LLC may make changes to specifications and product descriptions at any time, without notice. The product information on
the Robot Circuits Web Site is subject to change without notice.
9. Statutory laws. *
(i) some countries, regions, states or provinces do not allow the exclusion or limitation of remedies or of incidental, punitive, or
consequential damages, or the applicable time periods, so the above limitations or exclusions may not apply.
(ii) except to the extent lawfully permitted, this limited warranty does not exclude, restrict or modify statutory rights applicable to where
the product is sold but, rather, is in addition to these rights.
(*) European Consumer Centres provide information on EU-wide consumer laws as well as consumer laws for specific countries:
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Introduction
Welcome to the world of RCAT™ – We here at Robot Circuits believe you will find that the RCAT™ control board
is simply the most versatile, powerful, easy to use, and cost-effective control board on the market today.
This manual will introduce you to the many features that are resident on the board and will guide you through the
process of configuring the board for your specific application. But before we get started, please allow us to give you a
little background on why we even bothered bringing this board into existence…
First things first …
So what in the world does “RCAT™”mean?
Well, RCAT™ is an acronym for:
Robotic Controller based on the ATMega™ 2560 microcontroller by Atmel Corporation.
The RCAT™ is, put quite simply, one of the most powerful low-cost single board Microcontroller boards available on the
robotic enthusiast market today.
Consider this summary of the RCAT’s features:
The RCAT™ is based on the Atmel ATMega™ 2560 Microcontroller which features
o 256K of Program Flash ROM
o 4K internal EEPROM
o 8K internal SRAM
o 4 High-speed USARTS
o SPI port
o TWI (I2C) Interface
o Watchdog timer
o Many more features that you can view at Atmel.com
Direct access to 48 of the ATMega™2560’s most crucial I/O ports
Two 30V/400mA Mosfet drivers
128K External Static RAM (directly addressable by the ATMega™ 2560 as 2 pages of 64K each)
Most communications interfaces feature selectable as 3.3V/5V
Diagnostic 3-color LED
1M-bit Serial EEPROM
14 different communications devices/electrical interfaces/protocols/voltage levels
Power switch connection
Selectable onboard Vcc regulation or 5Vdc primary power input
On-board 3.3Vdc voltage regulator
Easy connection to Network via Serial-Ethernet Server (not included)
On-board USB connector with bridge to serial I/O system
3 channels of RS-232 RX/TX
ADXL345 3-Axis Accelerometer for fast, accurate measurement of inertial and attitudinal situations
Connectors oriented for easy connection to sonars, servo’s or any device requiring typical Gnd/Vcc/Signal
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
JTAG connector for instant connection to in-circuit emulators such as Atmel’s ATATMEL-ICE™
Flawless functioning with Atmel AVR Studio (current version 7.0)
Demo code included – contains full AVR Studio solutions featuring driver examples for the RCAT board devices as
well as several peripherals. Code is implemented using freeRTOS, a powerful open-source preemptive
multitasking operating system, with XRAM configured as heap space, fully functioning dynamic memory
management, and demo modules each implemented as scheduled tasks. Best of all, it works and doesn’t take 2
weeks of study just to get installed and running on your system!
One of the major features of the RCAT board is its rich array of communications options. All totaled there are 14 different
serial interfaces available. Although only a subset of these is available at any one time, the flexibility of the
communications system allows you to interface with almost any serial device you can imagine. The 14 interfaces include:
USART 0:
USB 2.0
RS232
RS422/485
USART 1:
Direct Connection at 5V
Indirect Connection at 3.3V
Indirect Connection at 3.3V to Ethernet Converter Interface Connector
USART 2:
Direct Connection at 5V – Full Duplex
Direct Connection at 5V – Half Duplex
Indirect Connection at 3.3V – Full Duplex
Indirect Connection at 3.3V – Half Duplex
RS232
USART 3:
Direct Connection at 5V
Indirect Connection at 3.3V
Uncommitted RS232 (1 channel featuring TX-IN, TX-OUT, RX-IN and RX-OUT access to Transceiver)
What are we trying to do that other boards cannot?
We at Robot Circuits are robotic system designers ourselves. Almost daily we live through the chore of selecting
hardware that is:
easy to use
has the most on-board power without having to buy this shield or that add-on just to get basic needs that are
common with almost every design
offers a sufficient amount of direct connection to the CPU
is a no-brainer to connect to ICE equipment
is fast
has high-current drivers on-board
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
includes lots of on-board communications capability (possibly our number one requirement)
is affordable
comes with good documentation
is easy to configure and get running for OUR APPLICATION
comes with actual working examples of useful code
It is not difficult to find project boards on the market that are little more than breakout boards, marketed with a
plethora of add-on boards and so-called “shields”. But what about us who need, say, a board that already comes
STANDARD with extended RAM so that we can implement dynamic memory allocation, or realtime O/S capability?
Sometimes we with real jobs and real deadlines just don’t have time or patience to shop around for what should be “the
basics”.
So, we designed the RCAT™ as an end-run around these issues. The RCAT™ comes STANDARD with:
128K of extended static RAM (divided into two 64K pages that are switchable via an I/O port)
An on-board ADXL345 accelerometer for easy inertial and attitudinal measurement
An onboard three-channel RS-232 transceiver
An onboard RS422/485 interface
An onboard USB bridge
An on board 1M-bit non-volatile RAM
Two onboard 30V/400mA mosfet drivers
A 3.3Vdc Voltage regulator with access to the outside world
In addition, we provide COMPLETE, FUNCTIONAL, LOAD-AND-RUN demonstration software that you can use as a
foundation for your application or just for educational purposes. This software is written with Atmel’s Atmel Studio™ in
mind. All that is required to get you up and running is the RCAT™ control board, a connection to an appropriate power
source, a PC capable of connecting to an ICE (in-circuit-emulator), an ICE (in-circuit-emulator) like the ATATMEL-ICE™, and a download of Atmel’s free Atmel Studio™ IDE. Once installed, you can simply load our project file and begin
running.
Of all the things that have irritated us at Robot Circuits over the years is downloading somebody’s “demo” code, only to
find that it is useless unless we are using some compiler or ide that is mainstream only to super-geeks, and even then
having to study, study, study just to figure out how to set paths, and compiler flags, and this and that and you name it.
Then – to find that the code doesn’t even do what we needed it to do.
We work in the real world and we needed real information that was relevant to solving real problems.
THAT is what we are striving for at Robot Circuits – to provide you with a “no-games”, professional-grade robotic control
platform that can actually DO SOMETHING!
We hope you find that we have accomplished this by helping you to achieve your goals.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
RCAT™ Board specifics
Power System
The power input schematic is shown in Figure 1 below:
Schemat ic
Figure 1
The power input connector, J3, allows several configurations and options for power to the board. The simplest and most
preferable is shown in Figure 2. In this configuration, a regulated 5Vdc is fed to J3 at pin 1. With JP3 installed, this routes
the 5Vdc immediately back out J3 on pins 2 and 5. Pin 2 is a redundant output where you can daisy-chain the 5Vdc to
other devices if desired. Pin 5 is meant for use when you need to switch the board itself on and off (independent of the
power supply). In this case, as show in Figure 2, you can place a switch between pins 5 and 6:
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Optionally, you can connect a shorting wire in place of the switch if you will be controlling the RCAT™ power from the
power supply itself.
The RCAT™ can be fitted with an optional onboard 5Vdc regulator (U4) for cases where you do not have 5Vdc already
available. As shipped the RCAT™ does not include this regulator. This is something you would add yourself. The chip
required is the LM7805C – TO220 and can be purchased here. Cost is around 68 cents. Figure 3 shows the land patterns
where this chip installs.
Figure 3
The RCAT™ draws about 500mA when it isn’t driving external peripherals. When driving other peripheral devices such as
devices utilizing the full capability of the mosfets (which can draw up to 400mA each), and sonar ranging modules, etc.,
the current requirements increase accordingly. The LM7805 is good for 1A which will (with adequate heatsinking) suffice
for moderate current requirements, but for most applications we recommend using an external 5Vdc supply rated for
3A which should cover the most extreme cases. Of course, your particular design requirements will drive this decision.
As shown in Figure 2, there exists an onboard 3.3Vdc regulator (U5) that supplies power to the onboard devices
requiring 3.3Vdc. These include the accelerometer (about 10mA max), the USB bridge chip (about 26mA max), and the
5V to 3.3V voltage translators (about 100mA max) for a total consumption around 136mA. The regulator employed is a
LM2937-3.3 that is capable of up to 500mA. Under normal conditions, 136mA does not require a heat sink. However, if
you plan to tap into the 3.3Vdc to power external devices you may need to fit U5 with an appropriate heat sink – not
doing so can damage the RCAT™ and will void your warranty.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Major Subsystems
The RCAT™ control board comprises several major subsystems. Some of these subsystems are broken out to connectors
on the board for access by external user hardware. Others are not. Still others have access to the outside world through
interim circuitry. For example, the extended RAM subsystem is not broken out for external access. This means that CPU
ports PA0 through PA7, PC0 through PC7, PG0 through PG2 and finally PJ7 are dedicated to this subsystem and thus are
not brought out to external connection points. Consider the extended RAM subsystem schematic:
Figure 4
We call such subsystems “dedicated” in that they use CPU ports fully dedicated to nothing other than the subsystem.
As mentioned above, other subsystems have breakout points on various connectors. These may be “direct” connections
to the CPU or they may be “indirect” connections. An example of an “indirect” subsystem is the USB interface subsystem
shown here:
Figure 5
As you can see, CPU ports RXD0(PE0) and TXD0(PE1) connect to the USB bridge chip and then to the external world
through the bridge. Although you have “access”to the ports, it is “indirect” through an onboard device (the CP2102 USB
chip).
The “direct” access subsystem consists of 37 connections broken out on J5 as shown here:
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Figure 6
Other ports that provide direct access are presented at other connectors that are configured for use by the alternate
port purposes. For example, connector J4 provides direct access to ports PF4, PF5, PF6, PF7 and the CPU reset input.
However, J4 is laid-out for direct connection to an in circuit emulator for use by the CPU JTAG system:
Figure 7
If you are not using the JTAG interface, these connection points are available for your use.
With the exception of PL0 and PL1 (discussed later), each of these points connects to and only to the port as labeled on
the connector. You are totally in control of these ports.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Ports PL0 and PL1 are a special case. They are shared with the control of the mosfet driver subsystem shown here:
Figure 8
As shown in the diagram on the left, from the CPU chip, ports PL0 and PL1 are connected on the board to the gates of
mosfets Q3 and Q4. However, they are also brought out to connector J5 via a pair of jumpers as shown in the right-hand
diagram. This enables you to control the gates either from the CPU via software or externally, by configuring ports PL0
and/or PL1 as inputs, and installing JP28 and/or JP29, thus bringing connection to the gates out to J5.
The third and final type of subsystem on the RCAT™ board is what we call a “bussed” subsystem. The primary system of
this type is the two-wire-interface (TWI) subsystem. Consider the following schematic:
Figure 9
Here we can see that CPU ports SCL(PD0) and SDA(PD1) interface with the onboard 1M-bit serial EEPROM (U3). But then
the ports are also connected to pullup resistors R5/R5 and then broken out for external access to J2 so that you have
direct access to the TWI subsystem as well.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
A complete list of all the subsystems on the RCAT™ is presented below:
Subsystem Name Type Access Connector Description And Associated Jumpers
LED Dedicated N/A Onboard Green/Yellow LED controlled by ports
PL6 and PL7
System Clock Dedicated JP1 16MHz Crystal with XTAL1 disconnect via JP1
Extended Static RAM Dedicated N/A A Cypress Semiconductor CY7C1019D-10VXI
RAM chip is provided onboard that makes 128K
bytes of static RAM available to the CPU in two
pages of 64K bytes. Page selection is managed
via dedicated I/O port PJ7. The chip I/O reserves
CPU ports AD0-AD7, A8-A15, and PG0-PG2 for
its exclusive use.
TWI Interface Bussed J2 Provides direct access to CPU ports PD0 and
PD1 (SCL/SDA) via J2 pins 8 and 6 respectively.
Resistors R4 and R5 pull these pins up to Vcc as
required by TWI. Two additional pins, J2/7 and
J2/5, provide access to the TWI bus through
bidirectional 3V level shifters for interfacing to
3V TWI devices.
1M-bit serial EEPROM Bussed J2 M24M01-RMN6TP serial EEPROM controllable
via CPU or external TWI at J2. See TWI details
above and EEPROM datasheet for details. Chip
write enable (/WC) is directly controlled by port
PD4 on CPU chip. This is not accessible outside
the CPU.
Accelerometer Bussed/Direct J5, JP23, JP30 The onboard ADXL345 accelerometer chip
Interfaces with the CPU on the TWI bus. This
means that it can also be accessed by the
external TWI connector J2. Jumper JP23 is used
to select the device address and jumper JP30 is
used to enable/disable the device via its /CS
pin. The interrupt outputs (INT1 and INT2) are
brought out to the CPU at PE4 and PE5
respectively. These are also brought out to J5 at
the PE4/PE5 pins. See the accelerometer
section later in this document for schematic and
detailed usage directions.
SPI Interface Direct J1 Direct access to Ports PB1, PB2, PB3, RST
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Subsystem Name Type Access Connector Description And Associated Jumpers
USART 2 Direct J7, J14 USART2 can be configured for any one of the
JP5, JP10, JP11 following :
Direct full duplex connection at 3.3Vdc
Direct full connection at 5Vdc
Direct half duplex connection at 3.3Vdc
Direct half connection at 5Vdc
Full duplex mode I/O available at J7
Half duplex mode available at J14
See USART2 configuration details later in this
document for schematic and jumper
configurations.
USART 3 Direct J8, USART3 can be configured for any one of the
JP12, JP13 following :
Direct connection at 3.3Vdc (I/O available at J8)
Direct connection at 5Vdc (I/O available at J8)
See USART3 configuration details later in this
document for schematic and jumper
configurations.
Power supply N/A J3, JP2, JP3, JP4 The RCAT™ board comes configured for
operation from a regulated 5Vdc 3Amp power
supply. It can also be configured for operation
from an unregulated input voltage of 7.5 to
35Vdc by installing an optional LM7805C
regulator in position U4. Please note that
adequate heat sinking is required if you choose
this option and install the regulator. It is up to
the user to provide adequate heat sink. The
RCAT™ has an onboard 3.3Vdc regulator for
powering the onboard chips and systems
requiring 3.3Vdc. This voltage is also available at
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Register
Bit
State
DDRL
6 1 DDRL
7
1
LED State
PL6
PL7
Off 1 1
Yellow
0 1 Green
1 0 Yel/Grn
0
0
Subsystems – Detailed discussion
In this section each of the above subsystems is discussed in more detail, including schematics to help you understand
the subsystem design and hopefully guide you to an understanding of how to use each.
LED
The onboard LED is controlled by the CPU from ports PL6 and PL7. In order to use the LED, both of these ports should be
configured as outputs through their associated Data Direction (DDR) registers.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
System Clock
The onboard 16MHz crystal provides the CPU timing reference.
Schem atic
Figure 11
Notes
Although rare, it is possible to “brick” the ATMega™ chip by improperly setting clock values in the programming
apparatus and even sometimes, again, very rarely, as a result of improper voltages or signals being applied to
numerous ports on the CPU. When that occurs, it is necessary to provide an externally generated clock to the
CPU in order to recover. There are plenty of how-tos available online in the event you should brick your board.
But one thing is always necessary – to inject an external clock into the XTAL1 input of the CPU. For this reason,
JP1 is provided so that you can remove the jumper and connect your external clock to the CPU. Hopefully you
will never need this, but in the event it happens, at least you won’t have to unsolder the crystal just to recover
your board.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Notes
128Kbytes of external static RAM are available to be used by the CPU. The ATMega™ 2560 only directly
addresses 64Kbytes. In order to make all 128Kbytes available, the RCAT™ board uses port PJ7 as address line
A16. The GCC compiler can be configured to utilize this RAM in a variety of ways. Please consult the
documentation for the IDE to learn the various possibilities. However, in no case is native support for more than
64Kbytes provided, so you will need to manage the paging via your own code. For most applications, 64K is
plenty of space, but the extra page is there if you need it.
The sample solution provided with your board configures most of page 1 of this RAM as heap and uses it in the
dynamic allocation functions such as malloc().
The CPU ports that interface to this RAM are not available for any other purpose on the RCAT™.
TW I Interface
Sometimes referred to as I2C (Philips Semiconductor Corp), the two wire interface (TWI) is a bus communication
system that forms an important communications channel on the RCAT™. Onboard devices that are controlled by
the TWI include:
1M-bit Serial EEPROM
ADXL345 Accelerometer chip
The TWI interface is also broken out for your use. Interface to a 3.3Vdc version as well as a 5Vdc version are
provided.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Notes
Connector J2 provides access to the TWI by you external devices. Pullups R4 and R5 are provided relieving you of
the need to pull the lines to Vcc. Also note the 3.3Vdc to 5Vdc level shifters (Q1/Q2) enable the connection of
3.3Vdc TWI devices to J2 pins 5 and 7. The example software solution provided with your RCAT™ board
configures the TWI for operation at 400KHz, so keep this in mind when connecting your device(s) and using the
example solution provided.
1M-bit serial EEPROM
The RCAT™ board includes a 1M-bit Serial EEProm chip, the STMicro M24M01-RMN6TP, for use however you
desire. This chip is managed via the TWI (described earlier). The schematic for this device is also shown above.
Please consult the manufacturer’s datasheets (M24M01-R) for details on how to properly use this device.
The example software solution provided with your RCAT™ board includes examples of how to read and write
from/to this device. Please note that since it hangs on the TWI, which is accessible from the outside world, you
could turn off any control from the CPU and use your own external control mechanisms to read and write this
chip.
Accelerometer
Onboard the RCAT™ is an ADXL345 accelerometer chip made by Analog Devices. Get datasheet here. The need
for an accelerometer in robotics applications is so commonplace that we decided to relieve our users from the
chore of buying and attaching a separate module dedicated to this purpose. This chip is a very powerful
accelerometer that features 3-axis measurement of attitudinal and inertial situations that make it possible to do
very accurate reckoning of position, tracking of motion and determination of pitch/roll/yaw in almost limitless
ways. The axis orientation of the chip is noted on the silkscreen of the RCAT™ as shown here:
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
A-B
0x3A
0x3B
B-C
0xA6
0xA7
The example software solution provided with your RCAT™ includes code to read this device and calculate pitch
and roll information. Of course, much more complex data manipulation is possible (see the Analog Devices
datasheet for details), but this example will provide you with the basic methods for reading and writing the
various registers on the device.
Like the EEProm, the accelerometer is hung on the TWI system so that you could control it externally is desired.
Referring to the schematic under the TWI section above you see two jumpers associated with this device.
Jumper JP23 determines the address at which the accelerometer is configured:
Position Write addr Read addr
Table 3
The accelerometer features two interrupt outputs that are actuated in response to certain events inside the
chip. These interrupt outputs are sent to the CPU on PE4 and PE5 as shown in the schematic in the TWI section
above. In addition these interrupts are broken out to connector J5 on positions PE4 and PE5 for monitoring by
your external hardware.
SPI Interface
CPU ports PB1, PB2 and PB3 are brought out to connector J1 as shown below:
Schem atic
As shown, access to the CPU /RST pin as well as Vcc and Gnd are also provided. J1 is laid-out to allow easy
connection to programming devices that utilize Serial Peripheral Interface (SPI). If not utilizing the SPI system,
these CPU ports are available for general purpose use.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
ADC AREF
Most applications will do fine using the CPU’s internal Vref for analog to digital conversion. For those
applications requiring an external reference, access to the AREF is provided as shown in the schematic below.
Schem atic
Please consult the ATMega™ datasheet for details on the proper implementation of this input.
Figure 16
JTAG
If y ou a r e u s i ng a n in-circuit - emul at or ( I CE) like the Atmel ATATMEL-ICE™, which we highly
recommend, the JTAG interface connect o r J 4 (shown below) provides a si m pl e pl u g -i n poi nt f o r
the ICE. If you are done wi t h o r a r e n ot ot h e r w ise using the connector for ICE or ot he r J TAG
pur p os e s, then CPU ports PF4 -PF7 are available to y o u r a pp l ication. Note that Vcc, Gnd and C P U
/RST are also accessible v i a J 4 .
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Mosfet Drivers
One feature missing on virtually every other robotic control board we know of is the ability to drive highercurrent devices from the board without the addition of extra add-on boards.
That’s where the onboard mosfet driver subsystem comes into play.
Schem atic
Two mosfet chips are provided. Each is a NX3008NBK,215 device from NXP Semiconductor. You can find the
datasheet for the device here:
http://www.mouser.com/ds/2/302/NX3008NBK-354913.pdf
Connectors JP26 and JP27 allow you to connect loads in a variety of ways. Here is one possible example using
the mosfet as a simple switch:
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Note:
When using an external power source as shown above, it is required to make sure the power source return is
common with the RCAT™ ground since the mosfets flow the load current to ground. This sets-up the possibility
of flowing (relatively) large currents through the RCAT™ ground causing ground noise. Although the ground
plane on the board will mitigate most of this, it is still best if you connect the return line of your external power
source to a ground point on the RCAT™ that is as close to JP26 or JP27 as is possible.
The best options would be one of the ground access points on I/O connector J5 like the following:
This example shows the use of mosfet Q3 with the return line of the external power source tied to J5 pin 32-C
which connects the return line to the RCAT™ ground at a point very close to the Q3 source pin (see the yellow
arrows).
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Install shunt
Alternatives for con trolling the mosfets
Notice the schematic below that the CPU port PL0 directly controls Q3:
Figure 21
Now notice in the diagram below that PL0 also connects to jumper JP28 which then goes to J5. This opens the
option of controlling the mosfet from the CPU or from an external source. Of course if you decide to utilize
external control you will need to install a shunt on JP28. You should also make sure that port PL0 on the CPU is
configured as a high-impedance input to avoid back-driving the external input and possibly damage one or both
ends of the circuit.
One possible configuration of this arrangement might provide for PWM control of the mosfet by connecting one
of the PWM outputs (for example J5 position 2 which is the PE3/OC3A PWM output from the CPU) to the PL0_A
input of J5.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Primary I/O Connector
First we will discuss connector J5 which we call the Primary I/O connector.
On the schematic you may see:
This indicates that connector J5 is a 3-row connector with rows A, B, and C. These row designators map to the
board as shown above. J5 has been laid-out this way to allow easy connection to devices that require signal, Vcc,
and ground connections in a 3-pin format. Most robot servos, sonar distance devices and other such devices are
designed this way.
To the right of the J5 are labels GND, Vcc, SIG which identify the purpose of each row. So – row ‘A’ connects to
each relevant port on the CPU, while rows B and C are common connections to Vcc and GND respectively.
Above J5 are labels that show what port the SIG row of each position connects to.
Just under J5 are position labels which are meant for easy reference. For example, J5 Position21-A refers to the
connection to CPU port PL1.
JTA G Con nector
Next in our discussion is connector J4 which serves as the JTAG connector as discussed in the JTAG section
earlier. If the JTAG functions are not required, then several of the pins on J4 are available for direct port
connection. Here is the schematic of that connector:
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
As illustrated, J4 gives you direct access to CPU ports PF4, PF5, PF6 and PF7. In addition you can access the board
ground, the CPU reset pin (/RST) and board Vcc. Pins 7 and 8 on J4 are not connected to anything.
SPI Co nnector
Similar to J4, discussed above, connector J1 serves a dual purpose. It gathers all the signals together that are
required for use in the CPU’s SPI system. See the ATMega™ manual for details on this. Alternatively, J1 presents
several ports for direct access. Here is the schematic:
As shown, J1 gives you direct access to CPU ports PB1, PB2, and PB3 along with Vcc, /RST, and GND access.
Figure 26
USART 0
There are no direct connection paths between USART0 and any connector on the RCAT™. All access to USART0 is
peformed through the USB, RS232 or RS422/485 interfaces.
USART 2 Port – J1 4 and J7
A complete discussion of the USART ports follows in the next sections. However, if you are not using the usarts,
most of them have direct access to their associated CPU port pins. J14 are J7 are is two of those. This is, perhaps,
the most challenging serial port on the board to understand, so we will show the annotated schematic to aid
you:
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Figure 27
As shown above, J14 is a 3-row header with each row having all its pins tied together. This allows wire-or’ing of
capable devices as described later in the USART 2 section. When not using this function, if you follow the bold
red line you will see that J14 row A pins eventually find their way to CPU port PH0 which is also the USART 2 RXD
line. In order to gain access to the port you must install shorting shunts on jumper JP9 across pins A-B and
jumper JP11 across pins A-B.
In similar fashion, access to CPU port PH1 (USART 2 TXD) is provided on connector J7 pin 1. Following the bold
green line on the above schematic you will see the signal path. To complete the path shorting shunts must be
installed on jumper JP8 across pins A-B and on jumper JP10 across pins B-C.
IMPORTANT!!
In this configuration you must ensure that jumper JP20 is NOT installed or the output from the level shifter
chip U9 will conflict with the CPU port.
3.3 Volt Input/ Output
As you can see in the schematic below, ports PH0 and PH1 can also be broken out as 3.3V I/O. By installing the
shunt on JP8 across pins B-C, and JP10 across pins B-C (follow the bold violet lines) the signal at J7 pin 1 can be
brought into the board as a 3.3Vdc level where it will be fed into U8 pin 20 and translated to a 5Vdc level for
forwarding to the CPU.
Likewise, following the bold blue lines on the schematic, by installing shunts on jumper JP11 across pins A-B and
JP9 across pins B-C, the signals present on J14 row A are sent through a similar translation on U9.
In this configuration, a shunt must be installed across jumper JP22.
While the 3.3Vdc to 5Vdc level translators ARE bidirectional, they ARE NOT TRANSPARENT…..the DIR inputs on
each translator must be set for the correct direction of signal flow. Referring to Figures 28, 29 and 30 above,
with the shunts installed as instructed, we see (following the violet line) J7 pin 1 reaching IC U8 on pin 20 which
is the B2 pin on the translator chip. The direction control of U8 is handled by signal XLAT1_DIR which connects
to the CPU on port PH7. First, PH7 must be configured as an output through its associated Data Direction
Register (DDR). Then, assuming the output of PH7 is high(1), this will configure translator U8 as an output from
the CPU to J7 since a logic 1 at the DIR pin causes the translator to conduct from the A side to the B side. With
PH7 low(0), then P7 pin 1 may be used as an input.
Of course, remember to set the CPU port DDR correctly. In the example just given, port PH1 DDR bit must be
configured.
Also, notice that both translators are Enabled or disabled in tandem by the state of port PG5 which connects to
the /OE pins of each translator.
For more information, consult the translator datasheets:
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Refer to Figure 31 below:
Schem atic
Direct access to CPU port PJ0 from J8 pin 2 is obtained by installing a shunt on jumper JP13 across pins A-B. See
the green lines in the figure. Likewise, direct access to CPU port PJ1 from J8 pin 1 is obtained by installing a
shunt on jumper JP12 across pins A-B. See the orange lines in the figure.
As in the previous section, both of these signals can be level-translated. See the operation of the level
translators in the previous section for details.
REMEMBER!!!
Never install JP21 anytime that JP13 is NOT in installed the B-C position! Also, if U9 DIR is set to make the
signal direction go from B to A (DIR = 0), then if JP21 is installed you must configure port PJ0 as an input (via
its DDR)!
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
USART 1 Port – J6
Connector J6 allows direct access to CPU ports PD2 and PD3 (via J6) if the USART 1 functions are not in use.
These connections can be routed through the 3.3Vdc to 5Vdc level translators in similar fashion to USARTs 2 and
3 as described earlier.
Refer to Figure 32 below:
Schem atic
With shunts installed on JP6 across pins A-B and on JP15 across pins A-B, you gain direct connection from J6 pin
1 to CPU port PD3. Refer to the bold orange lines in Figure 32.
With shunts installed on JP7 across pins A-B and on JP17 across pins A-B, you gain direct connection from J6 pin
2 to CPU port PD2. Refer to the bold blue lines in Figure 32.
As with USARTS 2 and 3 described earlier, J6 can be routed through the 3.3Vdc to 5Vdc level translators in
transit from J6 to/from the CPU chip.
Routing of J6 through the level translators is similar to the above USARTS, but there are a couple of twists to
consider.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Referring to Figure 33:
First, assuming all other things equal, the green signal path shows how you can route J6 pin 1 signal through
translator U8 in similar fashion to the previous USARTS by installing shunts on jumper JP6 across pins B-C and on
jumper JP15 across pins A-B.
Likewise the violet signal path shows how you can J6 pin 2 through translator U9 by installing shunts on jumper
JP7 across pins B-C and on jumper JP17 across pins A-B.
Unlike the USARTS 2 and 3, the isolation jumper, JP20 is handled differently than jumpers JP21 and JP22 are in
the other cases.
Also, please notice that U8 pin 7 connects directly to CPU port PD3. This is different from the other USARTS as
well.
These differences are due to the fact that USART 1 is shared between J6 and J10. See the portion of Figure 33
showing J10 near the bottom? J10 is intended for direct connection to a Netburner™ Serial to Ethernet
converter.
If J10 is not being used, then you will have no issues. If J10 IS being used, then you must make sure you do not
also bring conflicting signals into J6.
By paying attention to the schematics you should be able to navigate this arrangement with no problems.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
PORT
Access
Jumper(s)
PORT
Access
Jumper(s)
PB0
J5A/10
N/A
PF6
J4/3
N/A
PB1
J1/3
N/A
PF7
J4/9
N/A
PB2
J1/4
N/A
PH0
J7/2, J14A
JP9, JP11
PB3
J1/1
N/A
PH1
J7/1
JP8, JP10
PB4
J5A/11
N/A
PH2
J5A/7
N/A
PB5
J5A/12
N/A
PH3
J5A/8
N/A
PB6
J5A/13
N/A
PH4
J5A/9
N/A
PB7
J5A/14
N/A
PJ2
J5A/18
N/A
PD2
J6/2
JP7, JP17
PJ3
J5A/19
N/A
PD3
J6/1
JP6, JP15
PK0
J5A/26
N/A
PD5
J5A/15
N/A
PK1
J5A/27
N/A
PD6
J5A/16
N/A
PK2
J5A/28
N/A
PD7
J5A/17
N/A
PK3
J5A/29
N/A
PE2
J5A/1
N/A
PK4
J5A/30
N/A
PE3
J5A/2
N/A
PK5
J5A/31
N/A
PE4
J5A/3
N/A
PK6
J5A/32
N/A
PE5
J5A/4
N/A
PK7
J5A/33
N/A
PE6
J5A/5
N/A
PL0
J5A/20
JP28
PE7
J5A/6
N/A
PL1
J5A/21
JP29
PF0
J5A/34
N/A
PL2
J5A/22
N/A
PF1
J5A/35
N/A
PL3
J5A/23
N/A
PF2
J5A/36
N/A
PL4
J5A/24
N/A
PF3
J5A/37
N/A
PL5
J5A/25
N/A
PF4
J4/1
N/A
PF5
J4/5
N/A
One final note about USART 1…
In Figure 33 you can see how jumpers JP15 and JP17 can be installed across pins B-B thus connecting the signals
to an RS232 transceiver. This is discussed in detail in upcoming sections, but be aware that no direct connection
from this direction to USART 1 is possible.
Final comments about USA RT direct connectio ns
As can be seen direct connection to the CPU RXD/TXD ports at normal logic voltages (5V) is fairly simple.
However, when you decide to utilize the power of the level translators you must design your system carefully,
making sure you do not cause signal conflicts to arise. This involves not only making sure you connect your
hardware to the various connectors in the correct way, but it also involves making sure shunts are installed on
the proper jumpers across the proper pins, and it also involves making sure all CPU ports involved are correctly
configured as inputs, or outputs as needed, that the level translators being used are enabled or disabled as
desired (/OE), and that the DIR pin on each translator is set or reset as appropriate. Although this takes a bit of
planning, you will see that this layout provides you with a significant number of options for whatever
hardware/software system you are trying to create.
Summary of direct access ports
The following table summarizes the 48 CPU ports that are directlyaccessible on the RCAT™:
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Table 4
USARTS, and Serial C ommunications Interfa ces
This section details the several different types of communications interfaces available on the RCAT™. The
following is a list of all the different combinations you could have configured simultaneously.
USART 0:
USB
RS232
RS422/485
USART 1:
RS232
Ethernet (requires addition of Serial to Ethernet converter board such as Netburner™ SBL2E)
Logic (5Vdc)
USART 2:
Logic – Full Duplex (5Vdc)
Logic – Half Duplex (5Vdc)
USART 3:
Logic (5Vdc)
Given these possibilities, any of 24 different configurations can be created at any one time:
Note: All “logic” Interfaces are shown jumpered for 5Vdc operation
As shown in the configurations above, USART0 can be configured to use the RS422/485 interface. This interface
is accessible at connector J16. The interface utilizes the Exar SP3071EEN-L (follow link for datasheet). The
schematic is shown in Figure 34 below.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Free RS232 Channel
The RCAT™ has one channel of the ICL3243E RS232 Transceiver that is not committed to any USART or other
circuit on the board. It breaks out to connector J13 for use as you see fit. You can view the datasheet for the
ICL3243E here. The diagram is shown in Figure 35.
Schem atic
Ethernet System
We considered placing an Ethernet system on the RCAT™ board, along with a wireless transceiver like some
products do. However, we felt as though this is a critical system that deserves to be done in a comprehensive-
enough manner that we couldn’t justify trying to stuff something “good enough” onto this board. Instead we
opted to provide you with the connectivity via the various ports and serial protocols so that you can attach
whatever Ethernet or wireless hardware you so choose. This also relieves you of the burden of the requisite
coding that goes along with having such a system onboard.
We have had tremendous success with the Netburner™ series of Serial to Ethernet products. So we opted to
provide an interface to the Netburner™ SBL2E. You can view the product data here.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Referring to Figure 36 below, a 16 conductor ribbon cable connects nicely between J16 and the Netburner™. A
Network able can then be connected to the Netburner™ and you are fully Ethernet-enabled. The Netburner™
SBL2E costs around $37.00 depending on where you buy it and offers the cleanest most reliable Ethernet add-on
we have found.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Development Systems
Although many combinations of programming environments and hardware debugging and programming tools are
available, our goal is to get you up and running on your system as fast and inexpensively as possible.
To that end, we present some recommendations:
Programming IDE (int eractive Developmen t Environment)
Name: Atmel Studio
Manufacturer: Atmel
Languages: C, C++
Platform: Windows
Cost: Free – just must register an email address to download
Access at: http://www.atmel.com/products/microcontrollers/avr/default.aspx
RCAT™ Startup Solut io n Software
Name: RCAT
Manufacturer: Robot Circuits, LLC
Language: C
Platform: Windows, Atmel Studio 7x
Cost: Included with board purchase
In-Circuit Emulator
Name: ATATMEL-ICE
Manufacturer: Atmel
Platform: Windows
Cost: $92.94 (as of this publication date)
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Demonstration Software
Another point of aggravation that you have probably encountered at some time or another if you have been doing this
very long, is trying to gather up all the function libraries, configuring development environments, loading demonstration
code, downloading datasheets for various devices, and more, only to find that the library(s) you thought you wanted
were either out of date, or no longer available, or just plain broken, and the IDE configuration was cryptic and not
documented well enough to let you easily load the demo software, and the demo software was SO basic that it was, for
all intents and purposes, useless.
To that end we have provided a fully functional software solution that, once you have installed the Atmel Studio, and
have copied the solution files to the proper locations on your computer, can be simply loaded and executed without all
the usual drama.
We have provided the solution as a real-time operating system that uses a special AVR port of the open-source
FreeRTOS library (see the FreeRTOS page here). Please note that the RCAT™ Startup solution uses files from the
published release of FreeRTOS that have been adapted to run with the RCAT™ board. These files have been annotated
as such and renamed with an “RCAT_” prefix to identify them.
Yes – you SHOULD read the FreeRTOS documents and learn how to use the O/S. But the solution will load, compile and
run even if you don’t at first.
The solution provided is more than just a “Demo”. It can actually serve as a root project for your applications. In it we
have written examples for:
Operating the onboard LED
Configuring and reading the accelerometer chip (pitch and roll in degrees)
Accessing Extended RAM (the system comes configured to use Extended RAM as the heap and implements the
heap management routines of FreeRTOS, allowing dynamic memory management.
Reading and writing the 1M-bit Serial EEPROM
Reading and writing the Ethernet com (assumes a Netburner™ is attached)
Operating the onboard mosfets
Configuring a simple PWM-based servo control
Configuring one ADC channel and reading a voltage on it
Performing timer-based read of a sonar distance measurement device similar to the Parallax PING™
These modules are all written as separate tasks in the FreeRTOS multitasking system that can be installed, removed, or
reprioritized as you desire. Figuring out how to extend these tasks and how to extend the demonstrated techniques (for
example to operate other USARTs) is a simple jump from this point.
As time progresses, we will extend this solution to provide modules for interfacing to other popular devices. We also
welcome the addition of support for various modules on the github project.
RCAT-1A Rev A3 Designer’s manualSerious Power for the Serious Designer
Mechanical
In addition to the dimensional diagram (Figure 37), the RCAT™ board is available as a SketchUp model on the
Robot Circuits Website. You can download the file here.
Figure 37
Schematic Diagram
A complete schematic diagram of the RCAT™ control board is available in pdf format at