Raspberry Pi2 Board Support Package

This package contains project templates, system files and example programs for the Raspberry Pi Foundation Raspberry Pi2.

CrossWorks Version 3 Installation Instructions

This package can only be installed if you have the following CrossWorks license bolt-ons:

To install this support package
  1. Click the Tools > Package Manager menu option to open the package manager window.
  2. Right click on the Raspberry Pi2 Board Support Package entry and select Install Selected Packages.
  3. Click Next to take you to the summary page.
  4. Click Next to install the package.
  5. Click Finish to close the package manager window.
  6. Click the Tools > Show Installed Packages.
  7. Click on the Raspberry Pi2 Board Support Package link to view the package and its contents.
To manually install this support package
  1. If you have not done so already, follow the CrossWorks Tasking Library Package installation instructions.
  2. Download the file Raspberry_Pi2.hzq using your web browser.
  3. Click the Tools > Manually Install Packages menu option.
  4. Select the file you have just downloaded to install the package.
  5. Click the Tools > Show Installed Packages.
  6. Click on the Raspberry Pi2 Board Support Package link to view the package and its contents.

Release Notes

3.0

Documentation

Creating and debugging Rasperry Pi2 Projects

To create a new Rasperry Pi2 project
To build an application
To load an application using the Raspberry Pi2 micro SD card (and a host computer)
To debug an application via JTAG

Raspberry Pi2 Project Specifics

Target Startup Code

The startup code Raspberry_Pi2_Startup.s contains the exceptions vectors, reset_handler and irq_handler code. There are a set of preprocessor defines that configure the startup code which are documented in the startup file itself.

Target Reset Script

The reset script Raspberry_Pi2_Target.js stops the target then turns off and invalidates the cache. Since there is no (known) way to reset a Raspberry Pi2 under debug control you should reset any peripheral registers here if your application assumes them to be in a reset state.

CTL support

The file Raspberry_Pi2_ctl_board.c implements the ctl_set_isr, ctl_unmask_isr and ctl_mask_isr functions by programming the BCM2836 interrupt controller register group. The vector parameter to these functions corresponds to the interrupts table in the original BCM2835 ARM Peripherals document. The priority and trigger parameters to the ctl_set_isr function are not used. The startup code Raspberry_Pi2_Startup.s implements the irq_handler exception handler. This file also implements the CTL timer using the ARM Timer and has led and button support.

Header and Memory map files

The file Raspberry_Pi2_MemoryMap.xml describes the memory and peripherals of the Raspberry Pi2 and BCM2836. The file BCM2836_IO.h is a C header file that is generated from the memory map file.