Variable duty cycle using PIC 16F887

Discussion in 'The Projects Forum' started by Navaneeth1285, Apr 30, 2015.

  1. Navaneeth1285

    Thread Starter New Member

    Mar 19, 2015
    hi ,
    i have been working to develop a pwm signal of 25KHz and a variable duty cycle,
    i have used a external clock of 20MHz,i planned to use the pwm module available in the PIC16f887.
    i have been using the MPLAB X IDE,for compiling but i always find an error in the config statement,
    i tried changing to necessary syntax specified in the XC8 complier.
    but still it persists.Please tell me a solution for this problem.
  2. pwdixon


    Oct 11, 2012
    Looks like a format error, could be just as simple as adding a space after PWRTE before the =.
  3. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    Check the user's guide section 2.5.14. Put ALL the settings on one line. Do not use a semi colon on the end, this is not a C statement.