• AVR Freaks

Hot!Why can I find no record of Current-Controlled Mode

Author
davepl
Starting Member
  • Total Posts : 31
  • Reward points : 0
  • Joined: 2016/06/11 01:01:31
  • Location: 0
  • Status: offline
2020/10/27 02:02:53 (permalink)
0

Why can I find no record of Current-Controlled Mode

I was searching for the resistance of the PIC18F25K42's weak pull up resistor when I came upon a feature whereby you can control the current of the latch output. This would be very useful for controlling the intensity of an led but I can find no mention of the CCDCON, CCDPx[n] or CCDNx[n] registers. Is this a future feature or am I not looking in the right place.
#1

7 Replies Related Threads

    ric
    Super Member
    • Total Posts : 28933
    • Reward points : 0
    • Joined: 2003/11/07 12:41:26
    • Location: Australia, Melbourne
    • Status: online
    Re: Why can I find no record of Current-Controlled Mode 2020/10/27 02:57:13 (permalink)
    5 (1)
    davepl
    I was searching for the resistance of the PIC18F25K42's weak pull up resistor when I came upon a feature whereby you can control the current of the latch output.

    Where did you find mention of this?

    This would be very useful for controlling the intensity of an led but I can find no mention of the CCDCON, CCDPx[n] or CCDNx[n] registers. Is this a future feature or am I not looking in the right place.

    Where did you see mention of those registers?
    How can we comment if you are looking in the right place, when you don't reveal where you are looking?
     
     
     

    I also post at: PicForum
    Links to useful PIC information: http://picforum.ric323.co...opic.php?f=59&t=15
    NEW USERS: Posting images, links and code - workaround for restrictions.
    To get a useful answer, always state which PIC you are using!
    #2
    davepl
    Starting Member
    • Total Posts : 31
    • Reward points : 0
    • Joined: 2016/06/11 01:01:31
    • Location: 0
    • Status: offline
    Re: Why can I find no record of Current-Controlled Mode 2020/10/27 03:56:38 (permalink)
    0
    PIC18(L)F24/25K42 Data Sheet preliminary version, I noticed the preliminary part and downloaded a newer version and it has no record although xc8-2.3's pic18f25k42.h has this entry. I tried it out but it doesn't seem to work on my pic.
    // Register: CCDCON
    #define CCDCON CCDCON
    extern volatile unsigned char           CCDCON              __at(0x3ABE);
    #ifndef _LIB_BUILD
    asm("CCDCON equ 03ABEh");
    #endif
    // bitfield definitions
    typedef union {
        struct {
            unsigned DS                     :2;
            unsigned                        :5;
            unsigned EN                     :1;
        };
        struct {
            unsigned CCDS                   :2;
            unsigned                        :5;
            unsigned CCDEN                  :1;
        };
        struct {
            unsigned SEL0                   :1;
            unsigned SEL1                   :1;
        };
    } CCDCONbits_t;
    extern volatile CCDCONbits_t CCDCONbits __at(0x3ABE);
    // bitfield macros
    #define _CCDCON_DS_POSN                                     0x0
    #define _CCDCON_DS_POSITION                                 0x0
    #define _CCDCON_DS_SIZE                                     0x2
    #define _CCDCON_DS_LENGTH                                   0x2
    #define _CCDCON_DS_MASK                                     0x3
    #define _CCDCON_EN_POSN                                     0x7
    #define _CCDCON_EN_POSITION                                 0x7
    #define _CCDCON_EN_SIZE                                     0x1
    #define _CCDCON_EN_LENGTH                                   0x1
    #define _CCDCON_EN_MASK                                     0x80
    #define _CCDCON_CCDS_POSN                                   0x0
    #define _CCDCON_CCDS_POSITION                               0x0
    #define _CCDCON_CCDS_SIZE                                   0x2
    #define _CCDCON_CCDS_LENGTH                                 0x2
    #define _CCDCON_CCDS_MASK                                   0x3
    #define _CCDCON_CCDEN_POSN                                  0x7
    #define _CCDCON_CCDEN_POSITION                              0x7
    #define _CCDCON_CCDEN_SIZE                                  0x1
    #define _CCDCON_CCDEN_LENGTH                                0x1
    #define _CCDCON_CCDEN_MASK                                  0x80
    #define _CCDCON_SEL0_POSN                                   0x0
    #define _CCDCON_SEL0_POSITION                               0x0
    #define _CCDCON_SEL0_SIZE                                   0x1
    #define _CCDCON_SEL0_LENGTH                                 0x1
    #define _CCDCON_SEL0_MASK                                   0x1
    #define _CCDCON_SEL1_POSN                                   0x1
    #define _CCDCON_SEL1_POSITION                               0x1
    #define _CCDCON_SEL1_SIZE                                   0x1
    #define _CCDCON_SEL1_LENGTH                                 0x1
    #define _CCDCON_SEL1_MASK                                   0x2



    #3
    mbrowning
    USNA79
    • Total Posts : 1822
    • Reward points : 0
    • Joined: 2005/03/16 14:32:56
    • Location: Melbourne, FL
    • Status: online
    Re: Why can I find no record of Current-Controlled Mode 2020/10/27 09:18:13 (permalink)
    5 (2)
    Curious. All the K42 header files I've looked at have this phantom register, and the datasheets for all K42 devices have a note for address 3ABE in the SFR table that says "Reserved, maintain as '0'."
    Seems like there might have been something there at some point. Maybe pre-tapeout designs or even early silicon had an attempt at this feature.
    #4
    davepl
    Starting Member
    • Total Posts : 31
    • Reward points : 0
    • Joined: 2016/06/11 01:01:31
    • Location: 0
    • Status: offline
    Re: Why can I find no record of Current-Controlled Mode 2020/10/27 22:32:22 (permalink)
    3 (1)
    I downloaded the PIC18(L)F24/25K42 manual around May 2018, after I posted here I noticed the manual had preliminary printed in it so I downloaded the latest and unfortunately overwrote the preliminary one. I suspect that the feature never went into production for some reason or other. It stated that enabling it would disable I2c slew control.
    #5
    davepl
    Starting Member
    • Total Posts : 31
    • Reward points : 0
    • Joined: 2016/06/11 01:01:31
    • Location: 0
    • Status: offline
    Re: Why can I find no record of Current-Controlled Mode 2020/10/29 02:20:11 (permalink)
    5 (1)
    I found the preliminary manual on my laptop, for your interest I've attached the four relevant pages as jpegs

    Attached Image(s)

    #6
    NKurzman
    A Guy on the Net
    • Total Posts : 19023
    • Reward points : 0
    • Joined: 2008/01/16 19:33:48
    • Location: 0
    • Status: offline
    Re: Why can I find no record of Current-Controlled Mode 2020/10/29 11:04:58 (permalink)
    0
    That would have been nice, But I guess they could not get it to work and dropped it.
    #7
    dan1138
    Super Member
    • Total Posts : 3990
    • Reward points : 0
    • Joined: 2007/02/21 23:04:16
    • Location: 0
    • Status: offline
    Re: Why can I find no record of Current-Controlled Mode 2020/10/29 11:19:59 (permalink)
    0
    davepl
    I found the preliminary manual on my laptop, for your interest I've attached the four relevant pages as jpegs

    This is still on the Microchip site here:
     
    http://ww1.microchip.com/downloads/en/devicedoc/40001869b.pdf
     
    But the C version deleted the CCDCON register documentation.
     
    http://ww1.microchip.com/...ata-Sheet40001869C.pdf
     
    The silicon probably does not work.
     
    #8
    Jump to:
    © 2020 APG vNext Commercial Version 4.5