Hallo to all!
I would like to use PWM to controi load with mosfets. I used 5 channels of PWM at PIC16F1939 , but only CH1 (pin C.2) and CH2 (pinC.1) works..the other 3 channels (CH3-C.6, CH4-B.0, CH5-A.4) not work...PWM setup is simple, no wrong...I made a test with PIC16F1937 and all PWM channels works fine....Is there a problem with component or something else? I can't change the PIC because PIC16F1937 has different pins for PWM channels, and before make changes in PCB design I would like to know if is it possible to use all PWM channels of PIC 16F1939. Thanks.
PWM NOT WORK ON PIC16F1939
Moderator: Benj
-
- Posts: 115
- Joined: Wed Aug 03, 2016 10:45 pm
- Has thanked: 24 times
- Been thanked: 11 times
- Contact:
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: PWM NOT WORK ON PIC16F1939
Hello,
It looks like the definition file is wrong for the 16F1939, the PWM pins should match those of the 16F1937 device. Sorry for any inconvenience caused. The definition was using the 16F1938 pin configuration but this uses a smaller IC package.
Here is the corrected definition file.
When designing PCBs it's probably always wise to double check pin connections in the device datasheet just in case we have made a mistake. Of course sometimes there can be mistakes in the datasheets too so it's sometimes unavoidable.
It looks like the definition file is wrong for the 16F1939, the PWM pins should match those of the 16F1937 device. Sorry for any inconvenience caused. The definition was using the 16F1938 pin configuration but this uses a smaller IC package.
Here is the corrected definition file.
When designing PCBs it's probably always wise to double check pin connections in the device datasheet just in case we have made a mistake. Of course sometimes there can be mistakes in the datasheets too so it's sometimes unavoidable.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 115
- Joined: Wed Aug 03, 2016 10:45 pm
- Has thanked: 24 times
- Been thanked: 11 times
- Contact:
Re: PWM NOT WORK ON PIC16F1939
Thanks Ben , with corrected definition file for PIC16F1939 all PWM work fine....