Two 16F84 pics using one piezo?


Closed Thread
Results 1 to 12 of 12

Hybrid View

  1. #1
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    i can't comment on the SOUND command but if it's like PWM, sometimes the pin return to Input, sometimes to Output state so...

    As producing sound is not a big job, i suggest you to build a few line routine for that. That way, you'll be able to reach the exact resonnance frequency and get the maximum SPL of your piezo.

    Don't worry, the suggested method is safe.
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  2. #2
    Join Date
    Feb 2005
    Location
    Kolkata-India
    Posts
    563


    Did you find this post helpful? Yes | No

    Thumbs up Give it a try

    Hi,
    Use a series limiting resistor and give the port to port via capacitor scheme a try. You bet you can produce interesting effecting where one PIC generates the sound and the other modulates it.

    A recommendation would be to use a non-polar cap. Or two electrolytes back to back.

    BTW in this scheme both has to be an output.

    Regards

    Sougata

  3. #3
    Rubicon's Avatar
    Rubicon Guest


    Did you find this post helpful? Yes | No

    Default

    O.K then I'll give it a go and report back.

    I suppose if I really didn't want any beeping conflicts I could make the program check the pin for an input voltage before a SOUND command and if there is a voltage present then use another routine.

    Rubicon.

  4. #4
    Rubicon's Avatar
    Rubicon Guest


    Did you find this post helpful? Yes | No

    Default

    With both PICs PORTA.1 pins set as outputs and making them again outputs after each SOUND command just to be sure I tried the PortA.1-1uF ceramic capacitor-piezo-PortA.1 and PortA.1-10uF electrolytic capacitor-piezo-capacitor PortA. schemes.

    With both schemes I got the regular beep, a slightly louder regular beep and if both LED banks were completely in-sync the beeping sped up by a what sounded like a factor of four. That was it.

    Many thanks again,

    Rubicon.

Similar Threads

  1. connect two pics
    By soki in forum mel PIC BASIC Pro
    Replies: 28
    Last Post: - 23rd September 2008, 06:29
  2. Multiple Pics accessing single EEPROM
    By Atom058 in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 3rd February 2008, 17:22
  3. Retrieving infos from multiple PICs on a bus/chain
    By flotulopex in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 15th October 2007, 04:42
  4. Programming Pins of PICs?
    By Kamikaze47 in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 15th August 2007, 18:59
  5. Self Destructing pics? Copy protection
    By Rob Martin in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 22nd March 2004, 09:39

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