Instruction set PIC12F675


Closed Thread
Results 1 to 8 of 8
  1. #1
    Join Date
    Nov 2008
    Posts
    14

    Default Instruction set PIC12F675

    Hey,

    I'm writing a program in assembler language and i didn't find the multiply or divide opcode back in de instruction set.

    Is it wrong of me to assume that you can't myltiply or divide with the PIC12F675 or the whole PIC12 family?

    Thanks at advance,
    Ward

  2. #2
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,615


    Did you find this post helpful? Yes | No

    Wink Beginning by the beginning ...

    Hi, Ward

    I do think you're a beginner ... so, ...

    1) only the 18F,24,33 and 32 series processors have the HARDWARE multiplication aboard ...

    2) You are on a PICBASIC PRO Forum ... as the Compiler name states ... it's BASIC language and not assembler ...

    From 1) you understand the 10,12 and 16 series only can use SOFTWARE multiplication ...

    From 2) that you are not in the best place to get infos about assembler. I'd recommend you to join the MICROCHIP forums that mainly deal with assembler language.

    As a bonus, I greatly encourage you to read and Download THIS :

    http://www.mikroe.com/en/books/picmcubook/ch1/ ... ( all chapters )

    That might help you to understand what you try to play with ...

    Alain
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  3. #3


    Did you find this post helpful? Yes | No

    Default

    Acetronics;
    This is a GENERAL forum, so it's GENERAL information and questions.

    Lionheart;
    from what Acetronics has said the answer is no... the PIC12's don't have hardware maths, so you'll have to do multiply and devide in software...

    I'd reccomend if your PIC is going to be doing a lot of advanced maths then you'll definatly want to use a PIC18, the cost diference alone is not that much and means programs run a hell of a lot faster.

  4. #4
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,615


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by comwarrior View Post
    Acetronics;
    This is a GENERAL forum, so it's GENERAL information and questions.

    .
    YOU WRONG !!! NEVER BEEN A GENERAL FORUM ( you quite new here - end of june 2009 - ..., so read a bit before making YOUR rules. )

    MEL PICBASIC Forum
    ... everything in the title !!!


    General
    Area for general PIC BASIC discussion
    You are in THIS SECTION ...

    This is a PicBasic Forum ... but that doesn't mean some help can't be given for Assembler including .

    Alain
    Last edited by Acetronics2; - 5th October 2009 at 15:49.
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  5. #5
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    You're right, this is a PicBasic forum.

    And assembly language is a "HUGE" part of PicBasic Pro.
    If you don't know ASM, then you only know HALF or less of what PBP has to offer.

    Instead of telling people to go away...
    Learn ASM and help them. Or learn ASM in the process of helping them.

    You will be better off in the long run.
    <br>
    DT

  6. #6
    Join Date
    Nov 2008
    Posts
    14


    Did you find this post helpful? Yes | No

    Smile

    Thanks for the info.

    Acetronics:
    As you have guessed i am ideed a beginner with PIC controllers i only have some experience with the 8051 family. I will certainly read the info you gave me.

    comwarrior:
    I'd reccomend if your PIC is going to be doing a lot of advanced maths then you'll definatly want to use a PIC18, the cost diference alone is not that much and means programs run a hell of a lot faster.
    I originally thought that all PIC controllers had the multiply tool build in so i already bought the controller, but there isn't that many mathts so it should be doable. You learn from your mistakes, so next time i don't make the same mistake hopefullyhttp://www.picbasic.co.uk/forum/images/icons/icon7.gif.

  7. #7
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959


    Did you find this post helpful? Yes | No

    Default

    Here's a bunch of good math routines for PIC's in ASM.

    If it's not there ... you probably don't need it.

    Start with the "Basic math" link.

    http://www.piclist.com/techref/microchip/math/index.htm
    <br>
    DT

  8. #8


    Did you find this post helpful? Yes | No

    Default

    Thanks for the... correction... Darrel
    I'm currently immersed in your instant interupts, nice work, i like it

    Lionheart:
    I registerd on here in june granted...
    I started with the 16F877A running at 20MHz... I've recently baught a 18F4550 thats capable of running at 48MHz. Two reasons i've done it...

    The amount of maths i wanted it to do while maintaing it's scanning speed was getting rediculeous, it was starting to struggle with all the multiply and devides...

    Also, the extra speed (48MHz instead of 20MHz)

    The fact that the 18F4550 has additional ADC's, USB, and tonns more hardware... I just want the speed... lol

Similar Threads

  1. Pin won't stay high during Repeat...Until loop??
    By jellis00 in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 16th August 2009, 23:57
  2. Interruptus Frustratus
    By Byte_Butcher in forum General
    Replies: 16
    Last Post: - 17th April 2009, 20:36
  3. 16F628A - Stops if release power switch.
    By dene12 in forum General
    Replies: 16
    Last Post: - 14th February 2009, 07:57
  4. Help with sound command in 2 programs
    By hyperboarder in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 5th July 2007, 20:36
  5. error on compiling
    By parker in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 16th June 2005, 14:31

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts