Installation Instructions for chipKIT Pmod Shield-Uno Board Variant

The chipKIT MPIDE system provides a board variant mechanism that can tailor
the operation of the system to a specific circuit board. The installation of
a board variant requires that the board description files be placed in the
correct location in the MPIDE software installation, and an entry added to
the boards.txt file. This file provides the MPIDE with the basic properties
of the boards known to the system.

Step 1) Close any instances of MPIDE that may be running.

Step 2) Identify the location of the root of the MPIDE installation.
The MPIDE software is contained within a tree of directories (folders) on
the computer. Determine the path to this location. This path will be referred
to as <MPIDE> in the following steps.

Step 3) Copy the board variant description files.
The board variant description files for each known board variant are stored
in their own folder that is named for the board variant. These board variant
folders are stored in the following location within the MPIDE installation
tree:
	<MPIDE>/hardware/pic32/variants

The Pmod Shield board variant zip file contains a folder called:
	Uno32_Pmod_Shield

Copy the Uno32_Pmod_Shield folder to <MPIDE>/hardware/pic32/variants

Step 4) Add the board variant information to boards.txt
The boards.txt file is located at the followng location in the MPIDE
installation tree:
	<MPIDE>/hardware/pic32

This file contains a number of sections separated by a line of the '#'
character. Each section describes a board. Copy and paste the following
text into the boards.txt file. Ensure that text is inserted to create
a new section of the file and not in the middle of an existing section.

############################################################
uno32_pmod.name=chipKIT Uno32 with Pmod Shield

# new items
uno32_pmod.platform=pic32
uno32_pmod.board=_BOARD_UNO_
uno32_pmod.compiler.define=-Danything_you_want::-Danything=1
uno32_pmod.ccflags=ffff
uno32_pmod.ldscript=chipKIT-UNO32-application-32MX320F128L.ld
# end of new items

# Use a high -Gnum for devices that have less than 64K of data memory
# For -G1024, objects 1024 bytes or smaller will be accessed by
# gp-relative addressing
uno32_pmod.compiler.c.flags=-O2::-c::-mno-smart-io::-w::-ffunction-sections::-fdata-sections::-G1024::-g::-mdebugger::-Wcast-align
uno32_pmod.compiler.cpp.flags=-O2::-c::-mno-smart-io::-w::-fno-exceptions::-ffunction-sections::-fdata-sections::-G1024::-g::-mdebugger::-Wcast-align

uno32_pmod.upload.protocol=stk500v2
uno32_pmod.upload.maximum_size=126976
uno32_pmod.upload.speed=115200

uno32_pmod.bootloader.low_fuses=0xff
uno32_pmod.bootloader.high_fuses=0xdd
uno32_pmod.bootloader.extended_fuses=0x00
uno32_pmod.bootloader.path=not-supported
uno32_pmod.bootloader.file=not-supported
uno32_pmod.bootloader.unlock_bits=0x3F
uno32_pmod.bootloader.lock_bits=0x0F

uno32_pmod.build.mcu=32MX320F128H
uno32_pmod.build.f_cpu=80000000L
uno32_pmod.build.core=pic32
uno32_pmod.build.variant=Uno32_Pmod_Shield
#uno32_pmod.upload.using=

Step 5) Check that the variant is available.
Start MPIDE and access the Tools.Board menu. The following new
entry should be in the list of boards:
	chipKIT Uno32 with Pmod Shield

If this entry does not appear, the board information was
not entered into the boards.txt file correctly. Ensure that all
of the above noted text was placed in the file to create a new
section in the file.

If the entry does appear, select that as the board to use. Open
a sketch that is know to work correctly in the MPIDE and attempt
to build it using the Verify button on the tool bar.

If the sketch built correctly, then the new board variant has been
successfully installed into the system.

If it fails to build correctly, the most likely cause is that
the board variant description files were not placed in the
correct location.

Verify that the following folder exits:
	<MPIDE>/hardware/pic32/variants/Uno32_Pmod_Shield

and contains the following two files:
	Board_Defs.h
	Board_Data.c

Repeat Step 3) above.

