Looking for a real small PIC

Discussion in 'General Electronics Chat' started by R!f@@, Apr 22, 2014.

  1. R!f@@

    Thread Starter AAC Fanatic!

    Apr 2, 2009
    8,754
    760
    Hey Guys.
    I like to know if there is a PIC that I am looking for.

    Requirements are:
    1. SMD package.
    2. One ADC input or an I2C input
    3. 1 output (A PWM out is preferable ).

    Need to be 8 pin or less (less is better). Don't care about the package type. It needs to be a SMD.

    Project details :
    Need to light up a LED and fade it out within a second, Led is triggered by the ADC pin voltage or I2C address. That's it.
    Circuit needs to be as small as possible
     
    Last edited: Apr 22, 2014
  2. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,222
    Microchip have some 6 pins variants in SMD package. Try this http://www.microchip.com/maps/microcontroller.aspx I would perhaps avoid the 10F series as it is to spartan for me. Go for the 16F or 18F variants. Anyway always check if the chip is supported both by your programmer/compiler before ordering
     
    R!f@@ likes this.
  3. tshuck

    Well-Known Member

    Oct 18, 2012
    3,531
    675
    I'm fond of the 10F320, which fits the bill...

    Microchip's parametric search tool would reveal many more options for your specs.
     
    R!f@@ likes this.
  4. djsfantasi

    AAC Fanatic!

    Apr 11, 2010
    2,804
    833
    Not a PIC. Not SMD. But have you heard of the ATTiny85?

    Or maybe not.
     
    Last edited: Apr 22, 2014
  5. nerdegutta

    Moderator

    Dec 15, 2009
    2,515
    785
    R!f@@ likes this.
  6. BobTPH

    Active Member

    Jun 5, 2013
    782
    114
    Why, when he can get a PIC that meets his specs?

    Bob
     
  7. BobTPH

    Active Member

    Jun 5, 2013
    782
    114
    The PIC10F322 has 3 ADC inputs and 2 PWM outputs for $0.64 qty 1 in a SOT-23 package.

    Bob
     
    R!f@@ likes this.
  8. djsfantasi

    AAC Fanatic!

    Apr 11, 2010
    2,804
    833
    I almost deleted my post for this very reason! The other responses came in while I was typing...
     
  9. R!f@@

    Thread Starter AAC Fanatic!

    Apr 2, 2009
    8,754
    760
    Damn.. So many to look for.
    What the heck was I looking around for ( Did not find anything )
    Should have asked here first.

    Thanks a bunch fellows. I will check around while in workshop.
     
    Last edited: Apr 23, 2014
  10. JohnInTX

    Moderator

    Jun 26, 2012
    2,345
    1,028
    +1 Its a little jewel. It's also closer to midrange than baseline like other 10F PICs with a bigger stack, interrupts, LAT outputs (no more r-m-w headaches-better than midrange!), TMR0 has its own prescaler (not shared with WDT), TMR2 for a period/PWM timebase and it can write/read its flash to emulate EEPROM.

    If you decide to use it, be sure to pick up the AC244045 header board. This chip does not have built in debugging so you need the header (which has a special version of the 10f322) to do debugging with a PICkit. Get some in the DIP package for prototyping.

    I've been playing with a few and .. $0.64 Amazing.

    Have fun!
     
    R!f@@ likes this.
  11. THE_RB

    AAC Fanatic!

    Feb 11, 2008
    5,435
    1,305
    I believe he is using the MikroC PRO C compiler which does not (AFAIK) support 10F series PICs.

    To Rif@@; If you use a 10F series PIC you may need to program it in ASM.

    Your requirements of lighting a LED and "fading it out" over a second are trivial. You don't need a proper PWM module for that.

    I would pick up one of the really common hobby 8pin PICs with ADC like the 12F675.
     
    R!f@@ likes this.
  12. JohnInTX

    Moderator

    Jun 26, 2012
    2,345
    1,028
    It sure doesn't. Plus, it doesn't support uCHIP debuggers (programmers, yes) They have MicroICE for debugging.

    I would too, but I've also played with XC8 in the PRO mode on the smallest 10Fs. You can do quite a lot (at least more than I expected) in C on even the smallest ones. It makes pretty good code.
     
    R!f@@ likes this.
  13. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,388
    1,605
    I wouldn't buy any PIC device not marked "No assembly required." :cool:

    My tiny PIC of choice is the PIC12F615, 8 pins, DIP, SOIC, even a lead less chip carrier package. The 1K ROM let me fit code in C for an A2D controlled timer using the sample version of the Source Boost C compiler (one of the few available at the time).

    The best feature of this little device comes with the PIC12HV615 version: it has a built in 5V shunt regulator across the power pins. Just need a resistor and a cap to regulate the supply on it.

    That chip is a workhorse for me, I used it in at least 3 different projects, and the last one used two in each unit.
     
    R!f@@ likes this.
  14. R!f@@

    Thread Starter AAC Fanatic!

    Apr 2, 2009
    8,754
    760
    Ooook!

    PWM is not necessary . Good.
    What about I2C ?

    Is it available in 6 or 8 pin SMD PIC's ?
     
  15. R!f@@

    Thread Starter AAC Fanatic!

    Apr 2, 2009
    8,754
    760
    Man, that 10F320/322 in a SOT-23 package is Gooood!
    It might be just what the doctor wants.
    Smaller that 5mm LED.

    It might just do.

    Thanks Guys.
     
  16. THE_RB

    AAC Fanatic!

    Feb 11, 2008
    5,435
    1,305
    It won't have an MSSP (I2C) module.

    You can do I2C manually in code, but I would do it in C for ease and in that case a PIC with 2k word of ROM would be a good choice. A 1k PIC might leave you stranded if needing manual I2C, manual PWM and C code. (And yes I know the asm oldtimers could fit it in 1k easy, along with a USB stack ;))
     
  17. R!f@@

    Thread Starter AAC Fanatic!

    Apr 2, 2009
    8,754
    760
    Hey, that is great.
    I2C in code. Never knew that it could be done.
    Is it difficult.

    Do you think the 10F322 can do what I want.

    I just need to look for I2C address and trigger the LED ON and then just fade it out smoothly with in a sec or two then again wait for I2C command to trigger again.

    Is this possible ?
     
  18. THE_RB

    AAC Fanatic!

    Feb 11, 2008
    5,435
    1,305
  19. R!f@@

    Thread Starter AAC Fanatic!

    Apr 2, 2009
    8,754
    760
    I have 12F683

    The reason I am looking for the smallest one is a secret for now.

    The project is a secret. I have strict space limitations. You might laugh at what I am gonna do.

    How much space is required for coding I2C in software and give a fade out delay of 1 to 2 seconds?

    When the time comes it will be posted here.
     
  20. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,388
    1,605
    You want to make a slave I2C in code? Making a slave in hardware separates the men from the boys. Doing that in code... need 2 inputs, preferably both programmable edge triggered interrupts... not impossible, but why?

    All you need is a trigger. That is one wire. I2C takes 2 wires.

    If you are making an array of LED modules why not use ole reliable serial data?
     
Loading...