• AVR Freaks

Hot!Curiosity PIC32MEF Dev Board 2.0 user manual error

Author
MisterHemi
Super Member
  • Total Posts : 221
  • Reward points : 0
  • Joined: 2017/11/02 12:24:21
  • Location: Commerce, CA USA
  • Status: offline
2020/02/15 06:35:22 (permalink)
0

Curiosity PIC32MEF Dev Board 2.0 user manual error

I found on page-13 it shows RA2 and RA3 are the signals for the I2C on microBUS 1 &2.
 
However on page-27 it shows RA14 and RA15 as the signals for the I2C on microBUS1 & 2.
 
I need to know which is correct as I need to use I2C-1 and I2C-2. I cut the trace providing power to the pull-ups
for the I2C bus and plan to power them separately with one at 3.3V and the other at 5.5V.

My configuration:
MacBook Pro (Retina, 15-inch, Mid 2015) with MacOS Mojave (10.14.6) and MPLAB X IDE v5.30
 
Curiosity PIC32MZ EF 1 & 2, PIC24F Curiosity, XPRESS EVAL BOARD (PIC16F18855), SAMA5D3 Xplained and various custom boards.
#1

6 Replies Related Threads

    katela
    Super Member
    • Total Posts : 1631
    • Reward points : 0
    • Joined: 2013/06/11 05:25:18
    • Location: South Africa
    • Status: offline
    Re: Curiosity PIC32MEF Dev Board 2.0 user manual error 2020/02/15 06:40:00 (permalink)
    0
    Did you try a continuity test from the mikroBus socket to the PORT pins?

    Free online Microcontroller Tutorials and Projects for Hobbyists and students. From beginners to advanced. Website: www.studentcompanion.co.za
    YouTube Tutorials: https://www.youtube.com/StudentCompanionSA
    #2
    MisterHemi
    Super Member
    • Total Posts : 221
    • Reward points : 0
    • Joined: 2017/11/02 12:24:21
    • Location: Commerce, CA USA
    • Status: offline
    Re: Curiosity PIC32MEF Dev Board 2.0 user manual error 2020/02/15 11:02:17 (permalink)
    0
    katela
    Did you try a continuity test from the mikroBus socket to the PORT pins?


    No but I was thinking of doing that and posting the answer... i'll post the answer soon.
    They'll need to correct the documentation.

    My configuration:
    MacBook Pro (Retina, 15-inch, Mid 2015) with MacOS Mojave (10.14.6) and MPLAB X IDE v5.30
     
    Curiosity PIC32MZ EF 1 & 2, PIC24F Curiosity, XPRESS EVAL BOARD (PIC16F18855), SAMA5D3 Xplained and various custom boards.
    #3
    MisterHemi
    Super Member
    • Total Posts : 221
    • Reward points : 0
    • Joined: 2017/11/02 12:24:21
    • Location: Commerce, CA USA
    • Status: offline
    Re: Curiosity PIC32MEF Dev Board 2.0 user manual error 2020/02/15 14:06:35 (permalink)
    0
    Well.... this is odd... it seems the I2C located at J407 isn't working.
     
    I made a test project and connected my meter to SCL and SDA on J407.
    None of the pin for any of the I2C ports, when driven high, presented a voltage.
     
    I would uncomment the line for each of the ports to test them one by one.
    I only measure a voltage on the SCL and SDA on microBUS 1 & 2.
     
    On the versos 1 board they are 2 separate I2C busses (I2C-1 & I2C-2) however on 
    the version 2 board both microBUSes share I2C-1.
     
    Here is my test code:

     
     
     
    /*** DEVCFG0 ***/
    #pragma config DEBUG = OFF
    #pragma config JTAGEN = OFF
    #pragma config ICESEL = ICS_PGx2
    #pragma config TRCEN = OFF
    #pragma config BOOTISA = MIPS32
    #pragma config FECCCON = OFF_UNLOCKED
    #pragma config FSLEEP = OFF
    #pragma config DBGPER = PG_ALL
    #pragma config SMCLR = MCLR_NORM
    #pragma config SOSCGAIN = GAIN_LEVEL_3
    #pragma config SOSCBOOST = ON
    #pragma config POSCGAIN = GAIN_LEVEL_3
    #pragma config POSCBOOST = ON
    #pragma config EJTAGBEN = NORMAL
    #pragma config CP = OFF
     
     
     
    /*** DEVCFG1 ***/
    #pragma config FNOSC = SPLL
    #pragma config DMTINTV = WIN_127_128
    #pragma config FSOSCEN = OFF
    #pragma config IESO = OFF
    #pragma config POSCMOD = EC
    #pragma config OSCIOFNC = OFF
    #pragma config FCKSM = CSECME
    #pragma config WDTPS = PS1048576
    #pragma config WDTSPGM = STOP
    #pragma config FWDTEN = OFF
    #pragma config WINDIS = NORMAL
    #pragma config FWDTWINSZ = WINSZ_25
    #pragma config DMTCNT = DMT31
    #pragma config FDMTEN = OFF
     
     
     
    /*** DEVCFG2 ***/
    #pragma config FPLLIDIV = DIV_3
    #pragma config FPLLRNG = RANGE_8_16_MHZ
    #pragma config FPLLICLK = PLL_POSC
    //#pragma config FPLLMULT = MUL_33
    #pragma config FPLLMULT = MUL_100
    #pragma config FPLLODIV = DIV_2
    #pragma config UPLLFSEL = FREQ_12MHZ
     
     
     
    /*** DEVCFG3 ***/
    #pragma config USERID = 0xFFFF
    #pragma config FMIIEN = ON
    #pragma config FETHIO = ON
    #pragma config PGL1WAY = OFF
    #pragma config PMDL1WAY = ON
    #pragma config IOL1WAY = ON
    #pragma config FUSBIDIO = ON
     
     
     
    /*** BF1SEQ0 ***/
    #pragma config TSEQ = 0xFFFF
    #pragma config CSEQ = 0x0000
     
     
     
    #include <xc.h>
    #include <stdio.h>
    #include <stdlib.h>
    #include <string.h>
    #include <stdint.h>
     
     
     
    #define SYS_FREQ (200000000L)
    #define GetSystemClock() (200000000ul) // PIC32MZ System Clock in Hertz.
    #define FCY (200000000UL)
     
     
     
    #define led_1 LATJbits.LATJ7 // Red LED
    #define led_2 LATKbits.LATK7 // Green LED
    #define led_3 LATJbits.LATJ3 // Yellow LED
    #define led_4r LATBbits.LATB7 // Tri-Color LED Red
    #define led_4g LATBbits.LATB8 // Tri-Color LED Green
    #define led_4b LATBbits.LATB9 // Tri-Color LED Blue
     
     
     
     
     
    void main(){
    ANSELA = 0x00000000; // Disable analog functions on Port A (digital only).
    ANSELB = 0x00000000; // Disable analog functions on Port B (digital only).
    ANSELC = 0x00000000; // Disable analog functions on Port C (digital only).
    ANSELD = 0x00000000; // Disable analog functions on Port D (digital only).
    ANSELE = 0x00000000; // Disable analog functions on Port E (digital only).
    ANSELF = 0x00000000; // Disable analog functions on Port F (digital only).
    ANSELG = 0x00000000; // Disable analog functions on Port G (digital only).
    ANSELH = 0x00000000; // Disable analog functions on Port H (digital only).
    ANSELJ = 0x00000000; // Disable analog functions on Port J (digital only).
     
     
     
    TRISA = 0x0000; // Set all port A bits as outputs.
    TRISB = 0x0000; // Set all port B bits as outputs.
    TRISC = 0x0000; // Set all port C bits as outputs.
    TRISD = 0x0000; // Set all port D bits as outputs.
    TRISE = 0x0000; // Set all port E bits as outputs.
    TRISF = 0x0000; // Set all port F bits as outputs.
    TRISG = 0x0000; // Set all port G bits as outputs.
    TRISH = 0x0000; // Set all port H bits as outputs.
    TRISJ = 0x0000; // Set all port J bits as outputs.
    TRISK = 0x0000; // Set all port K bits as outputs.

    // Ensure LEDs 4a,b,c are off (high) because they're active low devices.
    led_1 = 1;
    led_2 = 1;
    led_3 = 1;
    led_4b = 1;
    led_4g = 1;
    led_4r = 1;

    /* Shared by mikroBUS 1 & 2 */
    //LATAbits.LATA14 = 1; // SCL1 (Pin 95) - Verified
    //LATAbits.LATA15 = 1; // SDA1 (Pin 96) - Verified

    /* Unknown location */
    //LATAbits.LATA2 = 1; // SCL2 (Pin 85)
    //LATAbits.LATA3 = 1; // SDA2 (Pin 86)

    /* Unknown location */
    //LATFbits.LATF8 = 1; // SCL3 (Pin 80)
    //LATFbits.LATF2 = 1; // SDA3 (Pin 79)

    /* Unknown location */
    //LATGbits.LATG8 = 1; // SCL4 (Pin 16)
    //LATGbits.LATG7 = 1; // SDA4 (Pin 15)

    /* Unknown location */
    //LATFbits.LATF5 = 1; // SCL5 (Pin 91)
    //LATFbits.LATF4 = 1; // SDA5 (Pin 90)

    while(1){
    }
    }
     
     
     

    post edited by MisterHemi - 2020/02/15 14:08:28

    My configuration:
    MacBook Pro (Retina, 15-inch, Mid 2015) with MacOS Mojave (10.14.6) and MPLAB X IDE v5.30
     
    Curiosity PIC32MZ EF 1 & 2, PIC24F Curiosity, XPRESS EVAL BOARD (PIC16F18855), SAMA5D3 Xplained and various custom boards.
    #4
    WaltR
    Super Member
    • Total Posts : 3799
    • Reward points : 0
    • Joined: 2003/11/07 12:38:21
    • Status: offline
    Re: Curiosity PIC32MEF Dev Board 2.0 user manual error 2020/02/23 06:23:20 (permalink)
    0
    Yep, the Board has ERRORS on the Silk labels.
     
    The Arduino connectors J407,408 and labeled backwards.
    For example: Label D0 is really D7, and GND label on J407 is really MOSI.
    The SDA & SCL are really on the labels D9 & D8.
     
    The issue is in fact much worse since the Silk label match an Arduino pin-out so it is the Connections that are wrong. An Arduino Shield board will not work if plugged onto the Curiosity.
     
    With that error I would not be surprised there are more errors.
    I found this by trying to use J407 & J408 to output OC signals during Code development for a project of mine.
     
    #5
    MisterHemi
    Super Member
    • Total Posts : 221
    • Reward points : 0
    • Joined: 2017/11/02 12:24:21
    • Location: Commerce, CA USA
    • Status: offline
    Re: Curiosity PIC32MEF Dev Board 2.0 user manual error 2020/02/23 22:55:11 (permalink)
    0
    Wow... I never found I2C-2
     
    They didn't think this out very carefully, even the decision to use a 12MHz clock wasn't the best choice. They should've left the 24MHz clock and some other things alone.

    As for the PKOB-4 it seems to work very good.

    My configuration:
    MacBook Pro (Retina, 15-inch, Mid 2015) with MacOS Mojave (10.14.6) and MPLAB X IDE v5.30
     
    Curiosity PIC32MZ EF 1 & 2, PIC24F Curiosity, XPRESS EVAL BOARD (PIC16F18855), SAMA5D3 Xplained and various custom boards.
    #6
    WaltR
    Super Member
    • Total Posts : 3799
    • Reward points : 0
    • Joined: 2003/11/07 12:38:21
    • Status: offline
    Re: Curiosity PIC32MEF Dev Board 2.0 user manual error 2020/02/24 07:27:21 (permalink)
    4.5 (2)
    Yes, very poor implementation and error checking.
    Poor decisions, like the Oscillator frequency) I can live with on a Dev board but ERRORS on connections is not acceptable on a released board. It happens on prototypes but must be found and corrected before moving to production.
     
    In my project I need to have and 9 OC modules outputting critical timing pulses. The issue I am having is getting these outputs onto Header pins. The Arduino header should support 8 OC's in pins that connect to PIC32 pins that can be mapped (RPn). So far I've only gotten 5 of the 8 outputs working.
    I did try Ohming from the headers to the PIC32 pins and seems not all are connected as per the schematic.
    Still working on this.
     
    #7
    Jump to:
    © 2020 APG vNext Commercial Version 4.5