choosing the adequate PIC microcontroller

Discussion in 'Embedded Systems and Microcontrollers' started by dreamcatcher, Feb 7, 2010.

  1. dreamcatcher

    Thread Starter New Member

    Jan 5, 2010
    27
    0
    Hi,

    I'm building a mobile robot which knows his coordinate.
    I need a 16bit register microcontroller to do the necessary calculations.
    also a need about 24 I/O port.

    Please can you help me to choose the adequate PIC microcontroller?:):)
     
  2. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,866
    988

    Microchip has a pretty cool search facility. Here is one for the 18F family. It is pretty easy to pic out what you need. (Pun intended :) ).
     
  3. dreamcatcher

    Thread Starter New Member

    Jan 5, 2010
    27
    0
    Yes but I need a 16-bit General purpose registers to do the calculations, and I think that 18F family is an 8bit.
     
  4. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,866
    988
    Do I need to build it for you too?

    Same search for 16bit


    Just teasing of course. :)
     
  5. dreamcatcher

    Thread Starter New Member

    Jan 5, 2010
    27
    0
    lol, yes if u don't mind :p

    by the way, do you have any simplified tutorial to start with the PIC24F family (I'v started learning about 16F familly) and now I'm obliged to swap to PIC24F, and this is why i've posted this thread because I hoped to don't move to another family after passing that much time with them lol

    thank you for your help ;):)
     
  6. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,866
    988
    Sorry I am just a newbie myself. But from what I have read, the higher you get in families, the harder it is to find tutorials. The 18F series is starting to get pretty good.

    What makes you think you need 16bits?
     
  7. dreamcatcher

    Thread Starter New Member

    Jan 5, 2010
    27
    0
    I need to develope a program where i'll use coordic transform to calculate the coordinate, and If i use an 8bit register i'll have a range of only 255mm, how ever if i use 16bit register it will be greater and simpler than using an 8bit register.

    PS: I'm working with the assembler.
     
  8. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,866
    988
    You enjoy punishing yourself don't you? :)


    You should consider C or BASIC. I think you will be able to do what you want to do in 8 bits pretty easily. Then again I could be totally wrong. :) But I think I am right. :)
     
  9. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,222
  10. dreamcatcher

    Thread Starter New Member

    Jan 5, 2010
    27
    0
    for the math problem i've already found a document that helped me a lot to do my routine ( http://www.microchip.com/stellent/idcplg?IdcService=SS_GET_PAGE&nodeId=1824&appnote=en520408 )
    which is easier and faster than floating point or C math functions "real time calculation"

    but my problem is that i have to enter a coordinate to my robot which will go to them. if i use an 8bit register i'll have a range of only 255mm which is small. and if use 16bit I will have a greater value and the routine stay the same. in the other hand I don't want to move to another PIC family because i did my designe acoording to PIC16F877 which I suppose that is easier than PIC24F (I'm new with microcontrollers).

    Is there any trick to use an 8bit register as an 16bit register?
     
    Last edited: Feb 8, 2010
  11. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,222
    As I said it is not a problem doing 16 bits calculations on your PIC. The trick is to use two 8 bit registers. This is described both in AN526 and AN617
     
  12. Markd77

    Senior Member

    Sep 7, 2009
    2,803
    594
    The app note and code you quoted is already doing 16 bit operations using pairs of 8 bit registers. Look in the source code for pairs of files ending in _H and _L
     
Loading...