The CC2400 single-chip RF transceiver provides a highly integrated, flexible low-cost solution
for applications using the world wide unlicensed 2.4 GHz frequency band. The CC2400DBK
demonstration board kit is a complement to the development kit (DK) as the hardware is
representative of an actual application, and it is well suited as a prototyping platform for
application code.
The CC2400DBK Demonstration Board Kit includes two CC2400DB Demonstration Boards.
These boards contain a CC2400 with necessary support components, an Atmel mega8 AVR
microcontroller, a PCB antenna, as well as a joystick, buttons and LEDs that can be used to
implement a visual user application interface. The demonstration board is also furnished with
connectors where all of the internal signals on the PCB are available.
This User Manual describes how to use the CC2400DBK Demonstration Board Kit. Atmel’s
AVR Studio and associated software is used to program and debug software. Please see the
reference section of this document for links to Atmel’s documentation on how to use their
tools.
Your CC2400DBK Demonstration Board Kit should contain the following items:
Kit contents
Item Number of articles
Demonstration Board (CC2400DB) 2
Quick Start instructions 1
CC2400 sample kit 1
RS-232 cables 2
Important:
Contact your local telecommunicat i on au thorities before transmitting an RF sig na l to ensure
that there are no local restrictions on the use of the 2400 –2483.5 MHz ISM ban d. The
CC2400 operates in the 2.4 GHz frequency b an d. Although this frequency band is usually
described as “world-wide”, some countries do not allow unlicensed operation in this ba nd .
SWRU048 Page 3 of 30
PCB
Figure 1 depicts an overview of the CC2400DB with description of the various components
embedded on the PCB.
RS-232
port
4-10 V
DC-jack
buttons
Optional 9V
battery
Joystick
MCU
section
Leds
PCB
antenna
CC2400 RF
section
3.3V voltage
regulator
1.8V voltage
regulator
Temp. sensor
Figure 1: CC2400DB overview
RF Section
The CC2400DB RF section includes all the necessary components for correct operation. The
CC2400 is connected to a 16 MHz crystal. A small 2.4 GHz PCB antenna is also included. RF
test and measurement equipment can be mounted the PCB by the use of an SMA connector,
by swapping capacitor placement of C63 and C62. See schematics for details. The RF layout
is identical to the CC2400EM, which is part of the CC2400DK Development Kit.
Important:
The CC2400DB demonstration board output power must be reduced for a 100% transmission
duty cycle to be compliant with the FCC 15 2
nd
harmonics regulation requirement. At the
moment the design is 1 dB above the limit.
Antenna
The PCB antenna is a so-called Inverted-F type. The Inverted-F antenna is a wire monopole
where the top section is folded down to be parallel with the ground plane. By folding the
antenna down you will reduce the height and maintain a resonant wire length. A capacitance
will be introduced to the input impedance of the antenna due to the parallel section. However,
as a rule of thumb design guide, the length + height (L+H) will be approximately equal to a
SWRU048 Page 4 of 30
quarter wavelength (λ/4). A reduction of the antenna height (H) will in general decrease the
antenna bandwidth. Please see figure 3 for the antenna dimensions.
Figure 2: Antenna dimensions
The height of the antenna is defined as the distance from the ground plane to the parallel
section, and the length is from the end of the antenna parallel section to the feed point.
Length: L = (26.19 mm – 9.19 mm + 1.22 mm x ½) = 17.61 mm
Height: H = (6.17 mm + 0.97 mm - 1.19 mm x ½) = 6.55 mm
Quarter wavelength: λ/4 = (L + H) = 17.61 mm + 6.55 mm = 24.16 mm
The physical size of the antenna is decreased somewhat compared to the theoretical length,
(λ = c/4*f = 3x10
8
/ 4x2.45x109) = 30.61 mm
SWRU048 Page 5 of 30
The radiated pattern for the PCB antenna was measured with the horizontal polarization
direction for the CC2400DB by measuring with vertical and horizontal mounting of the
demonstration board.
Important:
In practical range testing outdoors wi th line-of-sight (LOS) and use of the rf BlinkLed
application example, the f ollowing range has been verified at Chip con Norwa y with optimal
SmartRF Studio settings for the respective data rates:
1. Data rate settings 1 Mbps, range measured: 140 meters
2. Data rate settings 250 kbps, range measured: 240 meters
Please note that these range test s were performed at 0
°
C with a simple packet protocol, no
link margin, no robust protocol, close to the sensitivity limit of CC2400, and no retransmission.
0 degr.
Antenna
CC2400DB
Top view
Figure 3: Radiated pattern horizontal mounting
SWRU048 Page 6 of 30
Figure 3 depicts the antenna pattern while the CC2400DB is mounted horizontally with the
antennas parallel section aligned to the 0 degree direction.
Figure 4 depicts the antenna pattern while the CC2400DB is mounted vertically with the
antennas parallel section aligned to the 0 degree direction.
Power supply section
The power supply section contains two voltage regulators: a 3.3 V regulator for use by the
microcontroller and the I/O pins of the CC2400, and a 1.8 V regulator for powering the
CC2400 core.
A diode prevents permanent damage if wrong polarity is applied to the board. There are two
power connectors; a 2.5mm DC jack-type connector allows you to connect an unregulated
battery eliminator easily (the positive supply is on the center pin), and a connector for a 9V
battery on the bottoms side of the PCB. It is also possible to use 3 or 4 AA or AAA alkaline
cells to power the CC2400DB if a suitable battery pack is used.
SWRU048 Page 7 of 30
RS-232 interface
A serial port is included on the CC2400DB. This port is used when software is programmed
into the AVR MCU using the boot loader, and is also used by several of the example
programs. The port includes support for RTS/CTS-type hardware flow control (handshaking).
Important:
It is important to be aware that maximum data rate for the A tmega8 RS-232 interface on
CC2400DB is 38.4 Kbps due to the use of the internal RC oscillator. Please see th e Atmega8
datasheet for a baud rate error overview with the respect to a selected oscillator freq ue ncy.
Microcontroller and user interface
The microcontroller used is an AVR Atmega8L from Atmel. This controller has 8 KB of Flash
program memory, 1 KB of SRAM data memory and 512 bytes of non-volatile EEPROM data
memory. The controller runs on its internal oscillator, and is interfaced to the CC2400 via its
built-in SPI interface as well as some general I/O pins.
The MCU is also connected to three LEDs, a joystick and an extra button for user interface
purposes. The different examples use these peripherals differently. An analog temperature
sensor is also included.
An ISP connector is provided for programming the AVR without using the serial port. In this
case an Atmel AVR programmer should be connected to this connector.
All of the I/O pins are connected to footprints for 2 x 10 pin-row connectors. These connectors
are compatible with Agilent logic analyzer probes, and can be used either for testing or for
prototyping. For instance, it is possible to add a daughter board with additional circuitry using
these connectors.
AVR Pin
AVR pin name Pin usage I/O connector
Number
1 PD3/INT1 CC2400 DIO/DKT P4 pin 14
2 PD4/XCK/T0 Yellow LED P4 pin 7
7 PB6/XTAL1/TOSC1 Joystick up P3 pin 9
8 PB7/XTAL2/TOSC2 Joystick right P3 pin 7
9 PD5/T1 Joystick down P3 pin 6
10 PD6/AIN0 Joystick left P3 pin 3
11 PD7/AIN1 Joystick center push P3 pin 5
12 PB0/ICP RS-232 handshaking RTS, push
P3 pin 13
button
13 PB1/OC1A RS-232 handshaking CTS, Red LED P3 pin 17
RF circuits operating at high frequencies are normally sensitive to the physical layout of the
PCB. Chipcon has carefully optimized the layout of the CC2400DB Demonstration Board and
we therefore recommend that our customer copy, at least the RF parts and the decoupling
around the CC2400 when making their own PCB designs.
The PCB is of a 4-layer type in order to provide a well-defined ground plane as well as
adequate routing space. The laminate used is standard FR-4 board material. The PCB is
1.0mm thick, with layer 1 on the topside, layers 2 and 3 are internal layers and layer 4 is on
the bottom side. Layers 1 and 4 are used for routing, while layer 2 is a ground plane and layer
3 is used for power routing. All areas in the RF section that are not utilized for routing are
filled with copper connected to ground to provide RF shielding. The ground planes on all
layers are stitched together with closely spaced vias.
Note: The crystal X1 mounted on the EM board is a 16.000 MHz crystal, with ±10 ppm initial
tolerance, ± 10 ppm drift over temperature and a temperature range of –10˚ C to +60˚ C. The
crystal is designed for 16 pF load capacitance. In an actual application, the tolerance, drift
and temperature range of the crystal must be considered with application requirements in
mind. Please consult the data sheet and SmartRF
®
Studio for more information. It is possible
to choose a larger crystal package to save cost. The crystal should have an ESR of 60 Ω or
less.
The CC2400DB Demonstration Board is designed to be useful for quick prototyping, and also
for quick practical evaluation such as range testing.
Software can be programmed into the AVR microcontroller either using an external
programmer such as the AVRISP programmer or using the serial port to communicate with
the boot loader that is programmed into the MCU when the CC2400DB is shipped from the
factory. If the boot loader is overwritten when using an external programmer, the AVR must
be re-programmed with the boot loader before it is possible to program the AVR via the serial
port again.
When shipped from the factory, the CC2400DB contains the boot loader and a simple
example that will transmit a packet when a button is pressed, and blink a LED when a packet
is received. This example is ideal for range testing, for instance.
CC2400 Software download and evaluation using AVR Studio 4
Use a serial cable connecting the serial interface of the CC2400DB to the serial port of a PC
running AVR Studio and SmartRF
RF parameters for the CC2400 and AVR Studio 4 to control the CC2400DB, development
board.
®
Studio. You can then use SmartRF® Studio to find all the
220V
PC running
AVRStudio
Power
supply
Serial cable
4-10V
Serial cableCC2400DB
AVRISP
Programmer
Figure 12: Software download using AVR Studio 4
The CC2400DB demonstration board can be used for application software development. To
download new application examples a PC must be communicating with CC2400DB running
AVR Studio. AVR Studio can be downloaded free of charge from the world-wide-web.
The configuration of the processor fuses is only performed through the SPI interface using
the AVRISP programmer and AVR Studio 4. The AVRISP fuse window is depicted in figure
13. The CC2400DB is configured with the following fuses enabled:
3. Internal RC oscillator at 8 MHz Start up time 6CK + 0 ms
4. Preserve EEPROM memory through the Chip Erase Cycle
5. Boot vector enabled (default address = $0000)
SWRU048 Page 22 of 30
Figure 13: AVR Studio AVRISP Fuses Window
RC oscillator
The internal RC oscillator is used as reference time base. The oscillator frequency is
relatively independent of temperature and operating voltage. Its nominal frequency is 8 MHz.
A calibration feature utilising a calibration word programmed into the microcontroller at the
factory ensures that the oscillator frequency is equal from unit to unit. The calibration value is
stored at a fixed location in the EEPROM of the processor.
Microcontroller EEPROM mapping
The following map shows the data location. To customize the CC2400DB for a different
frequency, the EEPROM data can be replaced by new values found using the calibration
software. Please contact Chipcon Technical Support.
Note:
If a different RC oscillator frequency is used, a new calibration must be performed for the
desired frequency and stored at the correct location in EEPROM. The bootloader uses the
RS-232, so by changing the frequency the bootloader must be reprogrammed with the correct
baud setting for the frequency of choice. Please contact Chipcon Technical Support
EEPROM
Data Reference Comment
Address (hex)
0x01FF Calibration Value Calibration value is
only for 8 MHz
SWRU048 Page 23 of 30
Table 5: EEPROM memory map
In System Programming
Using the AVRISP in-circuit programmer or similar devices, the microcontroller can be
reprogrammed. The program code memory (flash) and the EEPROM can be reprogrammed.
AVRISP
Figure 14: AVRISP Program Window used to program flash or EEPROM
The device used for programming must be connected to the CC2400DB programming socket.
The programming interface uses 4 signal lines. These four lines can be accessed at the 6-pin
connector, P6. The pin out and description is listed in the table 5.
Signal/pin AVR
programming
socket, pin
MISO 1
SCK 3
MOSI 4
RESET 5
VCC 2
GND 6
SWRU048 Page 24 of 30
Table 6: ISP header connector
Bootloader
The CC2400DB is shipped with a bootloader. This loader communicates with AVR Studio.
After reset the bootloader must have a way to determine to start program mode or to run the
application software residing in the application code section of the flash. To start the
bootloader the Joystick center push on CC2400DB is used to enter program mode. This
button his held low after reset while starting the AVR Prog from the Tools menu in AVR
Studio until the bootloader program window is loaded. See figure 15 and 16.
Step-by-Step procedure:
1. Connect the CC2400DB serial port to your PC COM port
2. Connect power to CC2400DB
3. Start AVR Studio
4. Select Tools from the menu (See figure 15)
5. Reset CC2400DB and hold the Joystick Center push button down after reset and
start AVR Prog, bootloader will start (See figure 16)
6. Browse to find your application program *.hex file
7. Click on the Flash Program to program the flash
Important note:
If you should program the EEPROM p lease contact Chipcon Technical Support
8. Disconnect serial port
9. Reset CC2400DB
10. Start your application program
Figure 15: Starting AVR Prog in AVR Studio
SWRU048 Page 25 of 30
Figure 16: AVRprog bootloader Window
In the bootloader window the user can browse to the location of his application program and
program the application code section of the flash with the new application. After programming
is successful, reset the processor and the application code will start.
Important:
If the AVRISP programmer is used to program examples, the bootloader will be deleted if no
protection mode is applied to this sectio n of the processor flash. The bootloader is m o dified
source code from ATMEL AVR application note AVR109, Self programming and compiled
with IAR Embedded Workbench .
Introduction to examples provided with CC2400DB
The CC2400 Development Environment for the development of CC2400 software
applications is a combination of three tools, a text editor of choice e.g. (UltraEdit-32), a
compiler/assembler/linker and software platform provided by the processor manufacturer.
The CC2400 Development Environment is based on the “WinAVR”, which is a software
development tool. The WinAVR (pronounced “whenever”) is a suite of open source software
development tools for the Atmel AVR series of RISC microprocessors for the Windows
platform. It includes the GCC compiler for C and C++. This tool provides a framework for
most of the features supported by the Atmega8 microcontroller used with the CC2400DB
Demonstration Board.
The text editor of choice is primarily a tool for editing C source, assembler and make files.
However, it also provides syntax highlighting and other helpful functionality, such as a GUI
with possibility of project management, and C function highlighting.
Since the compiler/assembler/linker is integrated into another tool the text editor must be
configured with macros to support the make file provide with the for GCC compiler. More
SWRU048 Page 26 of 30
specifically the compiler converts one or more C source files into assembly code, which,
together with any handwritten assembler files are fed to the assembler. The assembler then
produces object files (machine code and binary data), which in turn are fed into the linker
together with the libraries and include files. Finally, the linker isolates functions and variables
that are actually used and produces an executable file in Intel HEX format that can be
downloaded into the FLASH memory of the Atmega8 microcontroller
Setting up a software project for CC2400
Before the CC2400 Development Environment can generate any target software it needs a
software project with consistent references to the actual target platform files is needed. These
references can be specified in the target project workspace of your text editor. See figure 17.
Figure 17: Software project workspace
Hardware Definition Files (HDF)
The hardware definition files (include files) define the hardware registers, interrupt vector
mapping and other hardware constants. They also include useful macros for the CC2400DB,
and all definitions generally support the C language.
The following files are included as hardware definition files,
• atmega.h
• CC2400.h
• devboard.h
• Utility.h
Hardware Library Files (HLF)
To support quick and easy program development Chipcon provides a library of macros and
functions that simplify hardware access to the CC2400 and the processor on the CC2400DB.
The files implement a hardware abstraction interface for the user program. As a result the
user program can access the e.g. microcontroller peripherals via function/macro calls without
specific knowledge about the hardware details
The following files are included as hardware library files,
• atmega.c
• CC2400.c
SWRU048 Page 27 of 30
• Utility.c
Configure output profile
The CC2400 Development Environment “build process” generates an executable file
according to the settings specified in the make file provided with the application examples
and by using the macros configured in the text editor. To support the processor target the
output file must be in the correct format.
With CC2400DB an RF link example is provided in the application code section of the
processor flash. The example is called rfBlinkLed. The application program is controlled by
the same push button as the bootloader, S2. See schematic layout for location of the button
on the PCB. Instead of powering up the board with the bootloader the board should be
powered up with the application code. The CC2400 is configured with default settings,
buffered mode, and a data rate of 1 Mbps.
Use the S2 push button to start the application. You will see that if you have no receiver up
and running the red LED will start to toggle. This means that you are not receiving
acknowledge form the receiver and thus have no link.
Data packet description
The data packet consists of a preamble, synchronization word, length byte, flag byte and a
data field. The length byte, flag byte and a fixed 10-byte payload are inserted by the
application.
The preamble, synchronization word and CRC is generated and inserted in the package by
CC2400. The data packet is shown in the figure 18.
Preamble
SOF
LENGTH
FLAGSPAYLOADCRC
Inserted by CC2400
Figure 18 The data packet used in the rfBlinkLed example
Data transmission protocol
The data transmission protocol is very simple, only using packet acknowledgement (ACK).
When the receiver receives a data package, the packet type is checked for CRC. If the
message is OK, it is shown on the green receiver LED, and an acknowledgement is sent as a
reply. However, if an acknowledgement packet that is received by the transceiver originally
transmitting, receival of the ACK is indicated on the yellow LED without any further reply. If no
acknowledgement is received the red LED will toggle.
LED
LED
Device is active as
long as S2 push
button is held down
DEVICE 1
DEVICE 1
DEVICE 2
DEVICE 2
Receiver polling
Receiver polling
Initial
Initial
trans-
transmission
mission
Message
Message
shown on
shown on
receiver LED
receiver LED
LED
RXLEDTX ACK
RX
TXRX
TXRX
Ack.
Ack.
trans-
transmission
mission
TX ACK
Acknowledge
Acknowledge
shown on
shown on
Transceiver
LED (ACK)
LED (ACK)
Figure 19 Data Transmission Protocol
SWRU048 Page 28 of 30
Troubleshooting
It does not work
•Make sure that the power supply is connected to the correct pins on the power
connector.
•Is the supply voltage correctly polarized? If not, the protection diode will prevent any
current from flowing. + and – are indicated on the PCB. On the DC jack, the tip is +
and the ring is –.
I cannot program the AVR using the serial port
•If you have programmed the AVR using an external programmer, you must use an
external programmer to program the AVR with the bootloader before you can use the
serial port to program the AVR again.
References
CC2400 Datasheet
Atmel Application note: AVR109 Self-programming (Bootloader for CC2400DBK is based on
this application note)