PIC32MX250 Pinguino
Language: | [[::PIC32MX250 Pinguino|English]] |
---|
Contents
Important Warnings for all Pinguino Users
Important Warnings: Please read the important warnings at least once!
Features
This board can run with either PIC32MX220F032B, PIC32MX250F128B or PIC32MX270F256B microcontrollers in the 32-bit Microchip family.
Characteristics of the board
- 32-bit MIPS M4K core running at 40MHZ
- 128kB (MX250) / 32kB (MX220) Flash
- 32kB (MX250) / 8kB (MX220) SRAM
- 19 digital I/O pins with 9 shared analog inputs
- 10 mA source/sink on all I/O pins
- 2 UART for serial communication
- 5 PWM outputs
- 9 analog inputs
- 10 bit ADC
- Peripheral Pin Select for mapping digital peripherals to various I/O ports for design flexibility
- Hardware RTCC provides clock, calendar & alarm functions
- Charge Time Measurement Unit (CTMU) supports capacitive touch devices
- Operating voltage 2.3 - 3.6V , 5.5V tolerant digital inputs.
Board overview
There is one reset button and one user button used to switch to bootloader mode.
This board can be powered by the USB connector (5V) or an external power supply.
If powered by VIN, voltage must be > 4.75V (will provide regulated 3.3V)
If powered by VBAT, voltage must be between 2.8V and 4.0V (NB : voltage won't be regulated to run low power modes).
Power sources are automatically selected. No jumper is needed.
Schematics
Preview
Building Instructions
Bill Of Components
Resistors
Part | Value | Color Code |
---|---|---|
R1 | 100K Ohm | brown - black - yellow |
R5,R6 | 10K Ohm | brown - black - orange |
R2 | 1K Ohm | brown - black - red |
R3,R7,R8 | 470 Ohm | yellow - purple - brown |
R4 | 10 Ohm | brown - black - black |
Capacitors
Part | Value | Comment |
---|---|---|
C1 | 22uF/16V | Electrolytic capacitor, marked as 22uF//16V |
C3,C5,C14 | 10uF/25V | Electrolytic capacitor, marked as 10uF/25V |
C7,C10,C12,C13,C2,C4,C6,C11 | 100nF | Ceramic capacitor, marked as 104 |
C8,C9 | 22pF | Ceramic capacitor, marked as 22 |
Diodes
- D2 3mm Red Led (Power Led)
- D3 3mm Yellow Led (User Led)
- D1,D4,D5 1N5817
Connectors
- J1 USB Type-B Female
- P2,P1 10-pin header (*)
- P3,P4 2-pin header (*)
- U2 2x 14-pin round-female header (PIC32MX250F128B socket)
(*) Use 2.54mm Single Row Male Header Strip if you want a breadboard-ready Pinguino, Female if you want it like an Arduino.
Others
- SW1 Push button (User button)
- SW2 Push button (Reset button)
- X1 8 MHz crystal (low profile)
- U1 TO220, B1117T-3.3 3.3V voltage regulator (or other LM1117)
- U2 PIC32MX250F032B or PIC32MX220F032B (28-pin DIP package)
- Q1 TO220, NDP6020P, P-channel Mosfet
- PCB
Before you start soldering
The PCB has 2 sides :
On the component side of the board, identify the holes corresponding to the component's leads. Insert the leads in these holes and slightly bend them on the other side of the board so that the component does not fall off when the board is turned over for soldering.
Turn the PCB over and put it on a flat and dry surface with component side facing down.
Hold the solder wire at the interface of any one of the leads and its pad and touch it with the soldering iron tip. The solder will melt and cover the pad within 3 seconds. Retract the soldering iron tip and the solder wire. Repeat this process to solder the remaining leads of the component.
For more info on soldering, see here.
Construction
Silkscreen view
- Place and solder all the resistors (R1 to R8). Resistors are not polarised, so it does not matter in which direction they are placed, but for aesthetic purposes it makes sense to have them all point in the same direction. Trim the wires.
- Place and solder all the 1N5817 diodes (D1, D4 and D5). The (black) band on the diode must be at the side of the white band on the PCB silkscreen (white print on the PCB). Trim the wires.
- Place and solder the two 22pF capacitors (C8 and C9, marked as 22). These capacitors are not polarised, so it does not matter in which direction they are placed, but it makes sense to place them so that you can still read their markings. Trim the wires.
- Place and solder the 8 MHz crystal. Trim the wires.
- Place and solder the 2 x 14 round female header strip (as a DIP28 socket).
- Place and solder the 8 100nF capacitors (C7, C10, C12, C13, C2, C4, C6, C11, marked as 104). These capacitors are not polarised, so it does not matter in which direction they are placed, but it makes sense to place them so that you can still read their markings. Trim the wires.
- Place and solder the 2 switch buttons (SW1 and SW2). Even if they look to be square, the four leads are not, so take extra care to insert the switch the right way round.
- Place and solder the 2 LEDs (red D2 and yellow D3). This is a polarised part so the shorter lead must be put connected to GND. In other words: insert the longer wire in the hole at the button side. Trim the wires.
- Place and solder the 3 polarised 10uF electrolytic capacitor (C3, C5, C14). The white stripe on the side of the capacitor must be at the opposite side of plus sign in the PCB silkscreen (in other words, at the edge of the PCB). Trim the wires.
- Place and solder the polarised 22uF electrolytic capacitor (C1). The white stripe on the side of the capacitor must be at the opposite side of plus sign in the PCB silkscreen (in other words, at the edge of the PCB). Trim the wires.
- Place and solder the USB connector (J1). Bend the two metal mounting tabs before soldering.
- Place and solder Q1 (NDP6020P, P-channel Mosfet) and U1 (B1117T-3.3, 3.3V voltage regulator). The metal back must be at the side of the white band on the PCB silkscreen (in other words, at the USB connector side). Trim the wires.
- Place the PIC32MX250 (or PIC32MX220) microcontroller in its socket. This will be easier if you first bend the two rows of pins a little bit in towards each other. Note that the microcontroller chip has a notch at one end. This notch must be at the end where the buttons switch are located.
- Connectors P1 to P4 can be soldered on both side. It's up to you.
ICSP Programming (if required)
In-Circuit Serial Programming (ICSP) is a way to upgrade/burn the Pinguino's firmware (bootloader).
Upgrading/burning the firmware is necessary only in two cases :
- you made your Pinguino yourself, you need to burn the bootloader only once.
- (in the unlikely event that) you crashed your Pinguino board.
If you bought a commercial board, the bootloader has been already burnt.
Hex files for Pinguino 32MX2x0 boards are available here
Using a PICkit-like programmer
Connect the ICSP cable to the Pinguino pins (see table below) and upload the firmware with (for ex.) MPLABX or with the Microchip Integrated Programming Environment (MPLAB IPE) that comes with MPLABX.
PicKit3 clone connected to the Pinguino 32MX250
ICSP Connector | Microchip name | Pinguino name | Pin on chip |
---|---|---|---|
1 | MCLR | RST | 1 |
2 | VDD | 3.3V | - |
3 | GND | GND | - |
4 | PGED1 | D12 | 4 |
5 | PGEC1 | D11 | 5 |
6 | NC | NC | - |
Using a Pinguino board
TODO
Testing the board
Step | Test | Expected Result |
---|---|---|
#1 | Connect the Pinguino board to a PC with a USB cable | Power led (red) should stays on |
#2 | Switch to bootloader mode | User led should blink at a high frequency |
#3 | Program the board with a simple example (see below) | User led should blink |
First Programs : 6 ways to blink a LED
Here are 6 ways to blink the built-in Led (User Led) on your new Pinguino board.
Troubleshooting
Problem(s) with your Pinguino hardware? Find help in the Forum here.
Before posting your problem read this.
Pin Out
Pin name | Label | Digital I/O | up to 5.5V tolerant | Analog input | Parallel Port | CTMU | Other (Periph. Pin Select) |
Pin on Chip | Microchip name |
---|---|---|---|---|---|---|---|---|---|
0 | D0 | Yes | No | AN9 | PMCS1 | CTED6 | SPI SCK2 | 26 | RB15/AN9/C3INA/RPB15/SCK2/CTED6/PMCS1 |
1 | D1 | Yes | No | AN10 | PWM4 SPI SCK1 |
25 | RB14/CVREFOUT/AN10/C3INB/RPB14/VBUSON/SCK1 | ||
2 | D2 | Yes | No | AN11 | PMRD | PWM3 SPI SDI2 |
24 | RB13/AN11/RPB13/CTPLS/PMRD | |
3 | D3 | Yes | Yes | PMD3 | CTED4 | I2C SDA1 SPI SS2 |
18 | RB9/TDO/RPB9/SDA1/CTED4/PMD3 | |
4 | D4 | Yes | Yes | PMD4 | CTED10 | SPI SDO2 I2C SCL1 |
17 | RB8/TCK/RPB8/SCL1/CTED10/PMD4 | |
5 | D5 | Yes | Yes | PMD5 | CTED3 | SPI SS1 | 16 | RB7/TDI/RPB7/CTED3/INT0/PMD5 | |
6 | D6 | Yes | Yes | PWM2 SPI SDI1 |
14 | RB5/TMS/RPB5/USBID | |||
7 | D7 | Yes | No | PMA1 | CTED9 | PWM1 SPI SDO1 |
12 | RA4/SOSCO/RPA4/T1CK/CTED9/PMA1 | |
8 | D8 | Yes | No | PWM0 | 11 | RB4/SOSCI/RPB4 | |||
9 | D9 | Yes | No | AN5 | PMWR | Serial Tx1 RTCC pin I2C SCL2 |
7 | RB3/AN5/C1INA/C2INC/RTCC/RPB3/SCL2/PMWR | |
10 | D10 | Yes | No | AN4 | PMD2 | CTED13 | Serial Rx1 I2C SDA2 |
6 | RB2/AN4/C1INB/C2IND/RPB2/SDA2/CTED13/PMD2 |
11 | D11 | Yes | No | AN3 | PMD1 | CTED12 | Serial Rx2 ICSP PGEC1 |
5 | RB1/PGEC1/AN3/C1INC/C2INA/RPB1/CTED12/PMD1 |
12 | D12 | Yes | No | AN2 | PMD0 | Serial Tx2 ICSP PGED1 |
4 | RB0/PGED1/AN2/C1IND/C2INB/C3IND/RPB0/PMD0 | |
13 | D13 | Yes | No | AN0 | PMD7 | CTED1 | USERLED | 2 | RA0/PGED3/AN0/CTED1/C3INC/RPA0/PMD7 |
14 | D14 | Yes | No | AN1 | PMD6 | CTED2 | USERBUTTON | 3 | RA1/PGED3/AN1/CTED2/RPA1/PMD6 |
USB D+ | D+ | No | No | CTED11 | USB | 21 | RB10/PGED2/RPB10/D+/CTED11 | ||
USB D- | D- | No | No | USB | 22 | RB11/PGEC2/RPB11/D- | |||
Vusb3V3 | Vusb | No | No | USB | 23 | VUSB3V3 | |||
Reset | Rst | No | Yes | Reset switch ICSP MCLR |
1 | MCLR |
How to get one ?
You can get a blank PCB, 32MX250 microcontroller with the USB bootloader pre-programmed or complete kit from the Pinguino Shop. Details below.
Kits
If you want to order a complete kit (including the PIC32MX250F128B microcontroller pre-programmed with the USB bootloader), please go to the Pinguino Shop
Europe VAT zone : 16.90 €
World (ex. VAT) : 13,97 € (about 19 US$)
Shipping cost : 2.00 €
Blank PCBs
If you just want the PCB with silkscreen to build your own Pinguino 32MX250, please go to the Pinguino Shop.
Europe VAT Zone : 6.05 €
World (ex. VAT) : 5.00 €
Shipping cost : 2.00 €
Pre-programmed PIC32MX250F128B
If you just want the PIC32MX250F128B microcontroller pre-programmed with the Pinguino bootloader to build your own Pinguino 32MX250, please go to the Pinguino Shop.
Europe VAT Zone : 6.05 €
World (ex. VAT) : 5.00 €
Shipping cost : 2.00 €