Author |
Message |
Topic: Motor Control Code |
Jammie1000000
Replies: 22
Views: 32117
|
Forum: General CCS C Discussion Posted: Thu Nov 12, 2015 5:42 pm Subject: Motor control code |
The code is still the same as on the previous page. |
Topic: Motor Control Code |
Jammie1000000
Replies: 22
Views: 32117
|
Forum: General CCS C Discussion Posted: Thu Nov 12, 2015 4:21 pm Subject: Motor Control Code |
I am happy with my setup. But I am always getting 3.3V into the four H Bridge inputs all the time. Obviously, I only want 1 or 2 inputs to be a high voltage while the rest are low to control the two m ... |
Topic: Motor Control Code |
Jammie1000000
Replies: 22
Views: 32117
|
Forum: General CCS C Discussion Posted: Thu Nov 12, 2015 2:55 pm Subject: Motor control code |
The power on doesn't seem to be a problem. When the button is pressed, the leds come on. The problem seems to be the motor control and I'm getting 3v from each of the four motor outputs into the h bri ... |
Topic: Motor Control Code |
Jammie1000000
Replies: 22
Views: 32117
|
Forum: General CCS C Discussion Posted: Thu Nov 12, 2015 11:12 am Subject: Motor Control Code |
This is the circuit layout. When the switch at B4 is on, the code should loop, asking whether there is an object in front or the LDR's change voltage. Then the motors should turn one way depending on ... |
Topic: Motor Control Code |
Jammie1000000
Replies: 22
Views: 32117
|
Forum: General CCS C Discussion Posted: Tue Nov 10, 2015 3:58 pm Subject: Motor Control Code |
I have brought the power on into the main while code, so should it not loop in this? I.e. checking to see if power is on, making sure the LED's are lit, then controlling the motor? I have attached the ... |
Topic: Motor Control Code |
Jammie1000000
Replies: 22
Views: 32117
|
Forum: General CCS C Discussion Posted: Mon Nov 09, 2015 6:43 am Subject: Motor Control Code |
The motors will turn if a simple output is made to the H-bridge. However, with my code, there is approximately a 3.3V going into all 4 of the H-bridge inputs. Obviously, this is why the motors aren't ... |
Topic: Motor Control Code |
Jammie1000000
Replies: 22
Views: 32117
|
Forum: General CCS C Discussion Posted: Sat Nov 07, 2015 11:39 am Subject: Motor Control Code |
I have altered the code (see below) and I have also attached the circuit design.
#include <16f877a.h> //set up microcontroller
#device ICD=TRUE
#fuses HS,NOLVP,NOWDT,PUT
#use dela ... |
Topic: Motor Control Code |
Jammie1000000
Replies: 22
Views: 32117
|
Forum: General CCS C Discussion Posted: Fri Nov 06, 2015 2:46 pm Subject: Motor Control Code |
Hi, I seem to be having some difficulty regarding my code. The hardware is set up correctly, i.e. i am receiving varying voltages from LDR's and IR sensors. However, I am not getting the motors to be ... |
|