Forum Replies Created
-
AuthorPosts
-
Ligo GeorgeKeymaster
Sorry, I don’t understand what are you doing and I haven’t seen any ultrasonic distance measuring section in your program.
One of the main mistake I found in your code is, you are not using open and closing braces of if statement correctly. Please correct it and recheck your code.
Ligo GeorgeKeymasterYou can directly connect the output of HM2007 module to input pins of pic microcontroller. Don’t forget to configure those pins as input by writing to TRIS register. It will be easy to program if you use same port for all those input pins. Then you can easily change the output of L293D for each inputs as per your requirements.
February 28, 2016 at 1:45 pm in reply to: INTERFACING OF DS1307 WITH PIC16F877A WITHOUT USING LIBRARY FUNCTIONS #12224Ligo GeorgeKeymasterYou can compare any of it, just use if statements.
Ligo GeorgeKeymasterThere is no track/pad provided in the pcb for that resistor. That pcb is designed for mosfet. You need to adjust it in the circuit.
Please post these doubts in the comments section just below the article.
Ligo GeorgeKeymasterNo, for AC motors you need to change the frequency of the sine wave.
Ligo GeorgeKeymasterYou can do the program by combining details in these two tutorials : Interfacing DC Motor with PIC Microcontroller and DC Motor Speed Control using PIC Microcontroller PWM. You need to calibrate the value of duty cycle with RPM, there is no other way.
February 3, 2016 at 6:32 pm in reply to: PIC Microcontroller Non-Blocking Delay Implementation #12111Ligo GeorgeKeymasterYou can adjust the delay by changing the 100 and 200 constants assigned to a and b respectively.
February 3, 2016 at 1:04 pm in reply to: PIC Microcontroller Non-Blocking Delay Implementation #12108Ligo GeorgeKeymasterSorry, I don’t understand your code. You have 3 infinite loops in your program. One in main loop, one in 1 min delay loop and other in 2 min delay loop.
You can try like this :
void main() { unsigned int a, b; UART1_Init(9600); // Initialize UART module at 9600 bps Delay_ms(100); // Wait for UART module to stabilize TRISB = 0x00; while (1) { if (UART1_Data_Ready()) { // If data is received, uart_rd = UART1_Read(); } if (uart_rd=='A') { LATB = 0x01; a = 100; } else if (uart_rd == 'B') { LATB = 0x02; b = 200; } uart_rd ='\0'; if(a > 0) { Delay_ms(1); a--; } else LATB = 0; if(b > 0) { Delay_ms(1); b--; } else LATB = 0; } }
February 1, 2016 at 9:55 pm in reply to: PIC Microcontroller Non-Blocking Delay Implementation #12102Ligo GeorgeKeymasterMy logic will be by using 2 variables.
- Increment each variable after a fixed delay or timer overflow if the corresponding LED is ON.
- Check each variable for the limit.
- If the limit is reached, turn OFF the corresponding LED and reset the variable to zero.
Ligo GeorgeKeymasterHi,
It depends on the required current. You can use 10K, if your target has only the IC. If your target board required more current, you need to change the resistor or even transistor.
Ligo GeorgeKeymasterYes, you can. I prefer 1N5818.
Ligo GeorgeKeymasterDear George,
You can’t do it using ADC interrupts. ADC interrupt will always generate when the A/D conversion is completed. But you can do it using Comparator Module of PIC Microcontroller.
Ligo GeorgeKeymasterIt will be very difficult to solve this problem by varying the resistance. Better try making the slight modification in the program.
Ligo GeorgeKeymasterHi,
Thanks for asking a good question.
2.7K is the bleeder resistor to discharge capacitors when the programmer is unplugged. It will prevent unintentional “Unrecognized Device” error by ensuring proper Power On Reset when you plug in next time.
Use this link for reference : http://www.microchip.com/forums/m245280.aspx
December 28, 2015 at 10:27 am in reply to: I2C Communication between Raspberry Pi and PIC Microcontroller #11936Ligo GeorgeKeymasterYou can use 3.3V pull up resistors instead of 5v pull up. Otherwise you can refer this also : https://www.adafruit.com/datasheets/an97055.pdf
-
AuthorPosts