ADC TO PWM PIC 16F887

Beta Testing discussion on mikroC PRO for PIC.
Post Reply
Author
Message
GEOSIGNALS
Posts: 1
Joined: 06 Apr 2016 17:17

ADC TO PWM PIC 16F887

#1 Post by GEOSIGNALS » 06 Apr 2016 17:38

Hello ALL here,I am a beginner in the language c and the compiler mikroc pro for pic.
I want to help with to build ADC TO PWM FOR PIC 16F887.
With knowledge of which I have so far I built the following programs which allows me to have a pulse in PORTB ,now I want to be able to adjust with a trimmer the duration of high-par by me ( 0 up to 500us)
please help me..



void main() {

ANSEL = 0;
ANSELH = 0;
TRISB = 0;
PORTB = 0;

do {

PORTB = 0b10000000;
Delay_us(500);
PORTB = 0b00000000;
Delay_us(9500);

} while (1);


}

User avatar
biljana.nedeljkovic
mikroElektronika team
Posts: 1043
Joined: 30 Jun 2015 15:15

Re: ADC TO PWM PIC 16F887

#2 Post by biljana.nedeljkovic » 07 Apr 2016 14:30

Hello,

You can check the PWM project in the compiler:
"C:\Users\Public\Documents\Mikroelektronika\mikroC PRO for PIC\Examples\Internal MCU modules\P16F887"

For more information check out our books, and of course, Libstock, where we store our projects.
http://libstock.mikroe.com/project_categories/

http://learn.mikroe.com/ebooks/piccprogramming/

Depending on your project, you an use many of our libraries including ADC and PWM library.
Check out the Help file in the compiler.

Best regards,
Biljana

Post Reply

Return to “mikroC PRO for PIC Beta Testing”