Searching \ for 'Using the PWM of the PIC 16c74' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: techref.massmind.org/techref/microchip/ios.htm?key=pwm
Search entire site for: 'Using the PWM of the PIC 16c74'.

Truncated match.
PICList Thread
'Using the PWM of the PIC 16c74'
1998\01\14@152230 by ttsltd

flavicon
face
I am looking for both a simple explanation of and coding for if possible the
use and setting up of the PWM outputs on the PIC 16c74.

Has anyone undertaken any work of this kind that they may wish to share with
me.

I would like to take a value from the A/D input (0 to 255) and simply put
this out as a PWM signal.

Any assistance will be appreciated.

Thanks in advance
spam_OUTAdrianTakeThisOuTspamttsltd.force9.co.uk

1998\01\14@175102 by Bob Blick

face
flavicon
face
If you already are familiar with the general operation of the PIC and its
ports, just set the pins as outputs, and then include these particulars:

;setup stuff
       movlw   b'00001111'     ;set for PWM not CCP1
       movwf   CCP1CON         ;to ccp1con for pwm channel 1
       movwf   CCP2CON         ;to ccp2con for pwm channel 2
       bsf     T2CON,2         ;turn on timer 2

;now make it work

       ;put your desired pwm value, 0-255, into w now!

       movwf   CCPR1L          ;to PWM register channel 1
       movwf   CCPR2L          ;to PWM register channel 2


This will get you started. There are other options, but start with this
and you can get to where you want to be.

Cheers,

Bob

More... (looser matching)
- Last day of these posts
- In 1998 , 1999 only
- Today
- New search...