pic24 beginner


Closed Thread
Results 1 to 24 of 24

Thread: pic24 beginner

Hybrid View

  1. #1
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    PicBasic compiles the basic code into assembly language.
    If you are using an 18F chip MPASM then converts the assembly into HEX.
    This is all done automatically when you compile your basic code. MPASM is free, it is part of MPLAB. When you purchase PBP a compatibe version of MPASM come with it.

    Now you need a way to "squirt" the hex into the PIC. That is where the PicKit2 comes into play. There are other programmers out there. If you do not go with the PicKit2 MeLabs has some good ones. Beware of the clones though. Nothing but trouble. The last I flecked the PicKit2 war around $50 US.

    So it boils down to needind PBP and a PicKit2 and a bread board or two and you should be good go.
    Dave
    Always wear safety glasses while programming.

  2. #2
    Join Date
    Aug 2009
    Posts
    63


    Did you find this post helpful? Yes | No

    Default

    ok thank you! you wouldnt believe how much thats helped!

    also just wondering for what ive described to you, is it important to buy the picbasic pro, or is the picbasic sufficient enough for my needs? or are there other programs i could use that would do the same thing at a lesser price?

  3. #3
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    To be honest, PB Pro is all I have ever used from MeLabs.

    Other programs... Folks around here seem to like PBP
    a few years ago before I purchased PBP I tried the demos from some of the others. And here I am. I think most would agree that PBP is the most stable one out there and the support from MeLabs if needed is great.

    Once you purchase PBP upgrades are only $25.
    Dave
    Always wear safety glasses while programming.

  4. #4
    Join Date
    Jul 2003
    Posts
    2,405


    Did you find this post helpful? Yes | No

    Default

    I will 2nd what Dave says. PBP is the only way to go. 90% of everyone that's ever
    purchased PBC from us over the years has returned within around 30 days to upgrade
    to PBP. It's the best out there.

    For your particular application, have a look at the 18F2431. The motion feedback module
    has a capture option specifically for frequency measurements, and makes it incredibly
    simple. It automatically captures the 16-bit timer5 value on every rising-edge.

    It also has 10-bit A/D with up to 200K samples-per-second, with simultaneous 2-channel
    sampling.
    Regards,

    -Bruce
    tech at rentron.com
    http://www.rentron.com

  5. #5
    Join Date
    Aug 2009
    Posts
    63


    Did you find this post helpful? Yes | No

    Default

    thanks for the feedback

    to bruce, you say the 18f2431 is specifically for frequency measurements. would that mean I would no longer need to attempt to code my program to measure the 0 points and then measure the frequency from the timings between the zero points? also you say it does two simultaneously? i have 3 phases from my analogue signal, which are split into 3 different signals, all of which i need to measure the frequency of and get an average. is this still possible with this pic?

    and would using the 18f2431 be alot easier than using a schmitt trigger and just measuring the frequency of 3 square waves using interupts? would there be 3 places on the pic i could make these inputs aswell?

    thanks
    Last edited by robertpeach; - 12th August 2009 at 10:55.

  6. #6
    Join Date
    Aug 2009
    Posts
    63


    Did you find this post helpful? Yes | No

    Default

    ive decided after looking through the specifications in high detail, i think the 18f2431 is probably best suited for my needs, since i noticed it does have 3 digital inputs for my 3 signals that need their frequency measured, and it has the schmitt trigger integrated into its inputs.

    im going to purchase the picbasic pro aswell, but im still dubious on the programmer... the pickit2, is a good site to purchase it from? and is the basic pickit2 good enough or is the pickit2 debug express something that is more suited for my needs?
    (i notice the pickit2 startup kit doesnt have enough pin slots for the 18f2431)

    thanks!

  7. #7
    Join Date
    Aug 2009
    Posts
    63


    Did you find this post helpful? Yes | No

    Default

    ok another reply by me...

    basically i was wondering if i bought a picbasic pro, usb programmer with a zif adapter, and pic18f2431 would work?

    additionally would purchasing a development board be something that would be needed? or anything of that such...

    thanks sorry for so many replys ive been pretty active at this, and im trying to learn basic without a program to even write it in yet!

  8. #8
    Join Date
    Jul 2003
    Posts
    2,405


    Did you find this post helpful? Yes | No

    Default

    you say the 18f2431 is specifically for frequency measurements
    The PIC is not specifically for measuring frequencies. It just has a capture module
    that makes it much easier to do since it will capture the value of Timer5 on every
    rising edge - which is the period of the square wave.

    also you say it does two simultaneously?
    It can take 2 A/D readings simultaneously.

    i have 3 phases from my analogue signal, which are split into 3 different signals, all of which i need to measure the frequency of and get an average. is this still possible with this pic?
    Yes.

    and would using the 18f2431 be alot easier than using a schmitt trigger and just measuring the frequency of 3 square waves using interupts? would there be 3 places on the pic i could make these inputs aswell?
    Yes it has 3 capture inputs, and using built-in hardware to measure frequency is a good
    deal easier than interrupts. All 3 capture inputs just happen to be Schmitt Triggers inputs
    too.

    If you do need to use interrupts, then I definitely recommend you take a look at Darrel
    Taylors' Instant Interrupt routines. He's done some awesome work on these.
    Regards,

    -Bruce
    tech at rentron.com
    http://www.rentron.com

  9. #9
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,172


    Did you find this post helpful? Yes | No

    Default

    If you intent to use the programmer for serious work forget pickit and look for something solid and fast one.

    I use for years the Pikprog2 that is discontinued and replaced by other newer models. The site is www.elnec.com and can program with ICSP or with a ZIF socket, PIC controllers, HCSxxx devices and EEPROMS too. New chips added every two months at no cost.

    There are others of course in the net.

    Ioannis

Similar Threads

  1. Replies: 17
    Last Post: - 12th April 2014, 03:17
  2. Replies: 0
    Last Post: - 29th August 2008, 06:54
  3. Beginner at PB
    By alphahr in forum Off Topic
    Replies: 1
    Last Post: - 21st April 2008, 18:43
  4. Beginner trying to use arrays
    By captain in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 3rd November 2007, 08:20
  5. Pic ID Error please help (beginner)
    By ninja in forum General
    Replies: 4
    Last Post: - 11th August 2005, 18:54

Members who have read this thread : 0

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