Control motor

Discussion in 'Programmer's Corner' started by pat33, Jul 27, 2014.

  1. pat33

    Thread Starter New Member

    Jul 27, 2014
    2
    0
    Hello,
    I would like to control a little motor supply: 5 volt 400hz by a PIC 18F4550
    Is it possible to do that ?
    Thanks for your help
    Have nice sunday
    Pat
     
  2. MaxHeadRoom

    Expert

    Jul 18, 2013
    10,565
    2,379
    Yes. :p

    Look up the CCP or ECCP module for PWM motor control.
    Max.
     
  3. pat33

    Thread Starter New Member

    Jul 27, 2014
    2
    0
    Thanks Max, I try this code ...but doesn' work :mad:

    Device = 18F4550
    Declare XTAL = 8
    Declare CCP2_PIN PORTC.1

    test:

    HPWM 1,127,0400

    GoTo test
     
  4. MaxHeadRoom

    Expert

    Jul 18, 2013
    10,565
    2,379
    I program in assembly, so I can't help there. :confused:
    Max.
     
Loading...