---
+ Post New Thread
Results 1 to 5 of 5
  1. #1
    Newbie level 2
    Points: 365, Level: 4

    Join Date
    Dec 2010
    Posts
    2
    Helped
    0 / 0
    Points
    365
    Level
    4

    How to detect the peak value of sine wave using 8051 microcontroller

    hi all,
    i am using 8051 in my project
    Last edited by rajendra_415; 6th January 2011 at 04:10.

    •   Alt31st December 2010, 06:31

      advertising

        
       

  2. #2
    Full Member level 3
    Points: 2,353, Level: 11

    Join Date
    Feb 2006
    Location
    Melbourne Australia
    Posts
    181
    Helped
    23 / 23
    Points
    2,353
    Level
    11

    Re: How to detect the peak value of sine wave using 8051 microcontroller

    1. Detect the zero crossings

    2. measure the period (20 ms), ie. the time between 2 positive going zero crossings

    3. divide the period by 4

    4. wait that time after a positive going zero crossing

    5. measure the sine voltage at that point.



    •   Alt31st December 2010, 08:26

      advertising

        
       

  3. #3
    Advanced Member level 2
    Points: 6,774, Level: 19
    blooz's Avatar
    Join Date
    Dec 2010
    Location
    India
    Posts
    561
    Helped
    124 / 124
    Points
    6,774
    Level
    19
    Blog Entries
    2

    Re: How to detect the peak value of sine wave using 8051 microcontroller

    Quote Originally Posted by ljcox View Post
    1. Detect the zero crossings

    2. measure the period (20 ms), ie. the time between 2 positive going zero crossings

    3. divide the period by 4


    4. wait that time after a positive going zero crossing

    5. measure the sine voltage at that point.
    in circuit u need ADC also ....and interface it to the controller ..Apply the above algorithm as given by ljcox .
    from the programming angle it will be easier if you make use of the interrupts external.

    ---------- Post added at 23:49 ---------- Previous post was at 23:31 ----------




    •   Alt1st January 2011, 18:19

      advertising

        
       

  4. #4
    Newbie level 2
    Points: 365, Level: 4

    Join Date
    Dec 2010
    Posts
    2
    Helped
    0 / 0
    Points
    365
    Level
    4

    Re: How to detect the peak value of sine wave using 8051 microcontroller

    Quote Originally Posted by ljcox View Post
    1. Detect the zero crossings

    2. measure the period (20 ms), ie. the time between 2 positive going zero crossings

    3. divide the period by 4

    4. wait that time after a positive going zero crossing

    5. measure the sine voltage at that point.
    hi thanks for u r reply
    will u please give me the example code for what u said



  5. #5
    Full Member level 3
    Points: 2,353, Level: 11

    Join Date
    Feb 2006
    Location
    Melbourne Australia
    Posts
    181
    Helped
    23 / 23
    Points
    2,353
    Level
    11

    Re: How to detect the peak value of sine wave using 8051 microcontroller

    Quote Originally Posted by rajendra_415 View Post
    hi thanks for u r reply
    will u please give me the example code for what u said
    I have not written any code for it.



+ Post New Thread
Please login