PIC32MX150F128 Breakout Board

Similar documents
An Introduction to Microchip's MPLAB IDE and an Example Application: LED Blinking

ECE 3740 SEP1: MPLAB Introduction and LED Blinking. An Introduction to Microchip's MPLAB IDE and

Configuration of Device Specific Features

32 bit Micro Experimenter Board Description and Assembly manual

PIC-32MX development board Users Manual

MPLAB XC32 USER S GUIDE FOR EMBEDDED ENGINEERS. MPLAB XC32 User s Guide for Embedded Engineers INTRODUCTION

DEV-1 HamStack Development Board

Introduction to Microcontroller Apps for Amateur Radio Projects Using the HamStack Platform.

Microprocessors B Lab 1 Spring The PIC24HJ32GP202

MT2 Introduction Embedded Systems. MT2.1 Mechatronic systems

Introducing the 32 bit Micro Experimenter

ET-PIC 24 WEB-V1. o Central Processing Unit (CPU) o System. o nanowatt Power Managed Modes. o Analog Features

Manual of Board ET-PIC STAMP 18F8722-K22 ET-PIC STAMP 18F8722-K22

PicProtoBoard 32MX Adapter User Manual

Introducing: New Low-Cost & Low Pin Count PIC Microcontrollers for the 8-, 16- & 32-bit Markets

PIC32&Overview& E155&

AKKON USB CONTROLLER BOARD

Embedded Systems. PIC16F84A Internal Architecture. Eng. Anis Nazer First Semester

DEVBOARD3 DATASHEET. 10Mbits Ethernet & SD card Development Board PIC18F67J60 MICROCHIP

KPIC-0818P (V050919) Devices Included in this Data sheet: KPIC-0818P

eip-24/100 Embedded TCP/IP 10/100-BaseT Network Module Features Description Applications

Display Real Time Clock (RTC) On LCD. Version 1.2. Aug Cytron Technologies Sdn. Bhd.

Getting Started with SKPIC32

PICado Alpha Development Board V1.0

The Freescale MC908JL16 Microcontroller

chipkit MX3 is the new name for Cerebot MX3. This board retains all functionality of the Cerebot MX3.

Microcontroller. BV523 32bit Microcontroller. Product specification. Jun 2011 V0.a. ByVac Page 1 of 8

eip-10 Embedded TCP/IP 10-BaseT Network Module Features Description Applications

SBAT90USB162 Atmel. SBAT90USB162 Development Board User s Manual

PIC-P67J60 development board Users Manual

BC-USB-Kit Manual. First Edition. February, BeatCraft, Inc.

TDSDB Features. Description

Contents. The USB Logic Tool... 2 Programming... 2 Using the USB Logic Tool... 6 USB Logic Tool Features... 7 Device Hardware...

LED Knight Rider. Yanbu College of Applied Technology. Project Description

SBC65EC. Ethernet enabled Single Board Computer

Microcontroller Overview

ootbrobotics.com Electronics and Robotics LLC

Approximately half the power consumption of earlier Renesas Technology products and multiple functions in a 14-pin package

An Introduction to Designing Ham Radio Projects with PIC Microcontrollers. George Zafiropoulos KJ6VU

All information, including contact information, is available on our web site Feel free also to explore our alternative products.

C and Embedded Systems. So Why Learn Assembly Language? C Compilation. PICC Lite C Compiler. PICC Lite C Optimization Results (Lab #13)

Nuvoton 4T 8051-based Microcontroller NuTiny-SDK-N78E715 User Manual

Typical applications where a CPLD may be the best design approach:

Breeze Board. Type A. User Manual.

_ V1.3. Motorola 68HC11 AE/AS POD rev. F. POD Hardware Reference

PIC32 MX1/MX2 Microcontrollers. Dave Richkas Product Marketing Manager High-Performance Microcontroller Division Microchip Technology Inc.

SBC44EC. Single board computer for 44 pin PLCC PICs

Section 32. High-Level Device Integration

_ V1.1. Motorola 6809 B POD rev. C. POD Hardware Reference

Arduino Uno R3 INTRODUCTION

Table of Contents Overview Functional Description Programming Tools... 4

AVR- M16 development board Users Manual

MPLAB SIM. MPLAB IDE Software Simulation Engine Microchip Technology Incorporated MPLAB SIM Software Simulation Engine

User Manual For CP-JR ARM7 USB-LPC2148 / EXP

Bolt 18F2550 System Hardware Manual

CEIBO FE-51RD2 Development System

The Atmel ATmega328P Microcontroller

Quickstart. Chapter 1

Product Overview -A 16 bit Micro Experimenter for Solderless Breadboards

USB Debug Adapter. Power USB DEBUG ADAPTER. Silicon Laboratories. Stop. Run. Figure 1. Hardware Setup using a USB Debug Adapter

PIC-LCD-3310 development board Users Manual

Section 33. Device Configuration (Part II)

1 Introduction to Computers and Computer Terminology Programs Memory Processor Data Sheet Example Application...

32 khz (typ.) embedded oscillator Oscillation stop detection circuit included

Easy Kit Board Manual

Breeze Board. Type B. User Manual.

Homework 5: Circuit Design and Theory of Operation Due: Friday, February 24, at NOON

1 Introduction to Computers and Computer Terminology Programs Memory Processor Data Sheet... 4

PCB-STM32-F3U. Development baseboard for the STMicro Discovery-F3 module (STMicro part# STM32F3DISCOVERY)

XC164CS Prototype Board

AVR Training Board-I. VLSI Design Lab., Konkuk Univ. LSI Design Lab

8051 Microcontroller

CSE 466 Exam 1 Winter, 2010

Nuvoton 1T 8051-based Microcontroller NuTiny-SDK-N76E885 User Manual

Dwarf Boards. DN001 : introduction, overview and reference

PIC Dev 14 Surface Mount PCB Assembly and Test Lab 1

Development board for PIC24FJ128GA010. with 262k TFT color LCD module

Microprocessors B Lab 3 Spring PIC24/24LC515 EEPROM Interface Using I 2 C

Gigatechnology.com Pty Ltd

AVR XMEGA Product Line Introduction AVR XMEGA TM. Product Introduction.

SBC45EC. Single board computer for 44 pin PLCC PICs

Laboratory: Introduction to Mechatronics. Instructor TA: Edgar Martinez Soberanes Lab 1.

SSD1963 EVK Rev3B User s Guide

Goal: We want to build an autonomous vehicle (robot)

Z8 Encore! XP F1680 Series 8-Bit Flash Solution with Extended Peripherals

Evaluation board for Microchip 100-Pin General Purpose Microcontrollers

CPT-DA Texas Instruments TMS320F28377D controlcard compatible. DA Series Interface Card. Technical Brief

LBAT90USB162 Atmel. LBAT90USB162 Development Board User s Manual

MicroBolt. Microcomputer/Controller Featuring the Philips LPC2106 FEATURES

Am186ER/Am188ER AMD continues 16-bit innovation

DBAT90USB162 Atmel. DBAT90USB162 Enhanced Development Board User s Manual

Section 42. Oscillators with Enhanced PLL

Embedded systems. Exercise session 3. Microcontroller Programming Lab Preparation

MICROPROCESSORS B (17.384) Spring Lecture Outline

Doc: page 1 of 9

Good Idea to Working Electronic Model

PIC-P28-USB development board Users Manual

DEV16T. LCD Daughter board

PIC-32MX development board User's Manual

CEIBO FE-5111 Development System

Transcription:

PIC32MX150F128 Breakout Board This is a description of a 32 Bit PIC32MX breakout board to be used for fast prototyping. It could also be used for conventional circuit boards to avoid the fine pitch of 64 pin packaged used by the device. In this case the board is piggy backed on the PCB board. A test program has been developed to verify the board and is described. The board is based on Microchip PIC32MX150F128 chip. A 44 pin TQFP packed is used. A total of 34 I/- pins are available. Bypass capacitors for power is provided on the breakout board as well as a connector for ICDA (In Circuit Emulation). The chip has the following features: 128 + 3 KB Program memory 32 KB RAM 32 remappable pins 5 Timers/Capture/Compare 2 UART 2 SPI/I2S 5 External Interrupts 3 Analog Comparators 2 I2C PMP 4 DMA Channels CTMU 13 10-bit ADC RTCC 34 I/O pins JTAG ICDA Chip pin layout is as in figure 1. The chip can use an internal RC-clock or use an external Chrystal for higher accuracy. The breakout board is prepared to use an external Chrystal. The CPU core is a DMIPS MIPS32 M4K running up to 48 MHz. The MCU has most of what you can expect from a modern microcontroller. A LED lamp indicates when power is applied. The power is 3.3 volts. The breakout board has two 22 pins 0.1 inch spaced connectors, similar to a big DIL circuit. This makes it easy to use the board on a solderless electronic prototype breadboard. All signal names are clearly visible with screened white text. An ICDA connector is mounted on the edge of the card. Via this connector you can connect a Microchip MPLAB ICD3 in circuit emulator. This gives you the possibility to download your programs to the program memory as well as debugging the program. You can set up to 6 breakpoints for this processor. One important notice! This board uses ICDA channel 2 (PGED2, PGEC2). You must enable this by a Pragma in your code as below: PIC32MX150F128 Breakout Board.docx, 2009-03-08 17:33, page: 1 (8)

// Debug Configuration #pragma config DEBUG = ON #pragma config ICESEL = ICS_PGx2 // ICE Background debugger = On. // Note, you must do this due to that com port #2 is used for ICS Figure 1, Pin layout of the PIC32 chip used (PIC32MX150F128D) The schematic is shown in figure 2. Note that C7, C8 X1 is optional. They are only used if you want to have a crystal based CPU clock. In most cases it will work without problem to use the on chip RC-clock. Use low ESR capacitors. The colors on the ICDA pin is the standard colors I use for my own cables and just a reminder. Be careful to connect with the right polarity, NMCLR must be connected to pin 1 of the ICDA connector. All ports are only labeled with their port name (A, B, C) and the pin name. You can use the cross table found in Microchip data sheet for the processor to find the other corresponding signals that are shared with a port. Bear also in mind that PIC32MX150FXX uses Peripheral Pin Select (PPS), you can decide by configuration commands which signal shall be assigned to a particular pin. In total we have 35 I/O pins that can be used, not including NMCLR (Clear/Reset signal). PIC32MX150F128 Breakout Board.docx, 2009-03-08 17:33, page: 2 (8)

Figure 2, schematic of the board. The pin configuration can be seen in table 1. J-Conn Jax-Pin DIL-pin Signal JA1 1 1 RB15/AN9_SCK2 JA1 2 2 RB14_AN10_SCK1 JA1 3 3 RB13_AN1 JA1 4 4 RB12 JA1 5 5 RB11_PGEC2 JA1 6 6 RB10_PGED2 JA1 7 7 RB9 JA1 8 8 RB8 JA1 9 9 RB7_INT0 JA1 10 10 RB6_SCL2 JA1 11 11 RB5_SDA2 JA1 12 12 RB4 JA1 13 13 RB3_AN5 JA1 14 14 RB2_AN4 JA1 15 15 RB1_AN3_PGEC1 JA1 16 16 RB0_AN2_PGED1 JA1 17 17 RA10 JA1 18 18 RA9 JA1 19 19 RA8 JA1 20 20 RA7 JA1 21 21 RA4_T1CK JA1 22 22 RA3_OSC2 J-Conn Jax-Pin DIL-pin Signal JA2 1 23 RA2_OSC1 JA2 2 24 RA1_AN1_SCL1 JA2 3 25 RA0_AN0_SDA1 JA2 4 26 RC0_AN6 JA2 5 27 RC1_AN7 JA2 6 28 RC2_AN8 JA2 7 29 RC3 JA2 8 30 RC4 JA2 9 31 RC5 JA2 10 32 RC6 JA2 11 33 RC7 JA2 12 34 RC8 JA2 13 35 RC9 JA2 14 36 NMCLR JA2 15 37 NC JA2 16 38 NC JA2 17 39 Vdd+3.3V JA2 18 40 Vdd+3.3V JA2 19 41 Vdd+3.3V JA2 20 42 GND JA2 21 43 GND JA2 22 44 GND PIC32MX150F128 Breakout Board.docx, 2009-03-08 17:33, page: 3 (8)

Table 1, Breakout Board Pin configuration Note that some signals can t be used with PPS and are bound to a particular I/O pin. These are included in table 1. In figure 3 you can see a computer generated 3D picture of the board (top side) Figure 3, Computer generated 3D picture of the board A photo of the breakout board can be seen in figure 4. In this case the internal RC generator is used to provide the internal clock. This simple setup was used for the initial test to check that the board was preforming as expected. Figure 1, PIC32MX150F128D Breakout board connected to MPLAB ICD 3 Test Program A test program was made for the board. The purpose was just to check that the basic functions where working correctly. Besides doing some simple outputs it also checks the CPU and the on chip RAM. The pragma section can be of particular interest, se figure below. // System clock selection #pragma config FNOSC = FRCPLL #pragma config FPLLIDIV = DIV_2 #pragma config FPLLMUL = MUL_24 #pragma config FPLLODIV = DIV_2 #pragma config FPBDIV = DIV_2 #pragma config FSOSCEN = OFF // Watchdog Configuration #pragma config FWDTEN = OFF #pragma config WDTPS = PS1048576 // RC OSC 8 MHz // Divide 8/2 to get 4 MHz // Multiply by 24 to get 96 MHZ // Divide 96/2 to get 48 MHz System Clock // Peripheral Clock Divisor gives 24 MHz // Must be off to use RB4 // Watchdog Timer Enable bit, Watchdog OFF. // Watchdog Timer Postscale Select bits, WDPS = Max. PIC32MX150F128 Breakout Board.docx, 2009-03-08 17:33, page: 4 (8)

// Debug Configuration #pragma config DEBUG = ON #pragma config ICESEL = ICS_PGx2 // Memory Configuration #pragma config CP = OFF #pragma config BWP = OFF #pragma config PWP = OFF // ICE Background debugger = On. // Note, you must do this due to that com port #2 is used for ICS // Code Protect Disabled. // Boot Flash write protect OFF. // Program Flash write protect OFF. #define SYS_CLK_MHZ 48 #define SYS_CLK_HZ 48000000L Note that this will give an infernal RC clock with a frequency of 48 MHz (20.8333 ns). I must admit that I actually wanted to have a 50 MHz clock but couldn t figure out how to get that figure. Perhaps somebody reading this can give an advice. A simple test program was developed. It uses one LED as an output indicator. The LED shall be connected to pin RC0 via a 470 ohms resistor. During the test the diode will blink fast. If the test is successful it will lit the LED with a steady green light for a while. It will after a delay start the sequence all over again. If it fails the LED will be turned off. The test program outputs the oscillator frequency (System Clock/SYSCLK) on pin RC3. You can easily verify this by connecting an oscilloscope to the pin. You will get a wave form as in figure YY. The test circuit setup is shown in figure x. Figure 5, test setup with the bread board PIC32MX150F128 Breakout Board.docx, 2009-03-08 17:33, page: 5 (8)

You will see the LED blinking rapidly for a while then become steady lit up and the go back to the blinking. During steady lit the CPU test program is executing. You can see the pulse at RC0 with an oscilloscope. On pin RC2 you will find a square wave. On RC3 you will find the CPU clock, see more below. Finally, on pin RB4 you will see a PWM signal, OC1. When using a PIC32MX150F128D MCU and outputting the REFCLKO signal to a port pin I get the waveform as in the figure below. The remarkable thing is that it has negative voltage swing and that it looks like a sinus. I expected the signal to be pure square and just a positive voltage swing above ground. Figure 6, REFCLKO signal at pin RC3, note the negative swing The small red doted horizontal line is the ground reference level. As can be seen from the figure the max is 3.125 Volt and the min -2.313 Volts. I did check the ground reference level with another signal. It is correct! I m confused of this behavior. Does anybody have experience of this behavior and can explain it? How can the signal be negative? CPU and RAM test functions The following test functions are within the test framework: DoCpuRegisterTest(); DoProgramCounterTest(); DoCheckerBoardRamTest(); DoMarchBRamTest(); DoMarchCRamTtests(); DoMarchCMinusRamTtest(); DoMarchCRamAndStackTest(); DoFlashCrcTest(); PIC32MX150F128 Breakout Board.docx, 2009-03-08 17:33, page: 6 (8)

DoCpuRegisterTest(); This function tests the 31 CPU Registers. This is a non-destructive test. Interrupts should be disabled when calling this test function. DoProgramCounterTest(); This is a functional test of the Program Counter (PC). It checks that the PC register is not stuck and it properly holds the address of the next instruction to be executed. DoCheckerBoardRamTest(); This function implements the Checkerboard test on the RAM memory. This is a non-destructive memory test. The content of the tested memory area is saved and restored. The test operates in 64 bytes long memory chunks at a time. DoMarchBRamTest(); This function implements the March B test. This test performs 32-bit word RAM accesses. The address of the RAM area to be tested must be 32-bit aligned and the size of the tested RAM area must be an integral multiple of 4. The tested RAM memory will be cleared when the control returns so this is a destructive memory test. DoMarchCRamTtests(); This function implements the March C test. This test performs 32-bit word RAM accesses. The address of the RAM area to be tested must be 32-bit aligned and the size of the tested RAM area must be an integral multiple of 4. This is a destructive memory test. DoMarchCMinusRamTtest(); This function implements the March C Minus test. This test performs 32-bit word RAM accesses. The address of the RAM area to be tested must be 32-bit aligned and the size of the tested RAM area must be an integral multiple of 4. This is a destructive memory test. DoMarchCRamAndStackTest(); This function implements the March C test on both a RAM and a stack area. First the RAM area is tested using the standard March C test. If the test succeeded the requested Stack area is copied into the RAM area that has just been tested and then the March C test is run over the Stack area as if it were a regular RAM area. The saved Stack area is restored and the result of the test is returned to the user. Once the Stack area is tested, the SP register is restored. This is a destructive memory test. DoFlashCrcTest(); This function calculates the 16-bit CRC of the supplied memory area using the standard Linear Feedback Shift Register (LFSR) implementation. It calculates the CRC over the memory area between the start address and end address and returns the CRC Value. This test is non-destructive for the memory area to which it is applied. The above test functions use a bit structure to set the result of each individual test, se below: volatile struct ClassB_Test_Flags { unsigned cpuregister_testresult : 1; PIC32MX150F128 Breakout Board.docx, 2009-03-08 17:33, page: 7 (8)

unsigned programcounter_testresult:1; unsigned checkerboardram_testresult:1; unsigned marchcram_testresult:1; unsigned marchcminusram_testresult:1; unsigned marchcramstack_testresult:1; unsigned marchbram_testresult:1; unsigned flash_testresult:1; unsigned clock_testresult:1; unsigned clockline_testresult:1; } testflag; If the specific test has passed the corresponding bit is set to True (1), if it fails it will be set to False (0). Note that the two last bits for clock tests are not implemented in this incarnation. If the LED will be switched off, indicating an error, of check these bits for the probably cause. The memory test program uses malloc to allocate memory. Therefore it s important to set up the Heap due to the fact that malloc the heap to acquire memory. To set up the heap see figure 7 as an example. Note also that the stack size is set as well. Figure 7, Project build options to get a Heap Note that this project was developed and compiled using MPLAB IDE V8.92. However it should be rather straight forward to import it to the new MPLAB XC development environment. Regards Bo, SM6FIE References 1. Circuit diagram, pdf file 2. PCB DXF files, zip file 3. Test Framework, zip file Keywords: PIC32, PIC32MX150, Breakout Board, PIC32 Test program, REFCLKO, Class B Test software, Microchip PIC MCU PIC32MX150F128 Breakout Board.docx, 2009-03-08 17:33, page: 8 (8)