Forum Replies Created
-
AuthorPosts
-
nitish kumar singhParticipant
reply sir?
If you have such program that is used to control the Gate then please sent it to my mail id [email protected]
nitish kumar singhParticipantfollowing program is correct for rotating the stepper motor half revolution in clock wise and anti-clock wise.?
My aim is to use this stepper motor to close and open the Railway crossing gate..
#include<reg51.h>
void MSDelay (unsigned int value);
sbit sense1=P1^0;
sbit sense2=P1^1;
void main ()
{
int i;
P1=0x03;
{
if ((sense1=='1')&& (sense2!='1'))
{
for (i=0;i<=2;i++)
{
P2=0x01;
MSDelay (10);
P2=0x02;
MSDelay (10);
P2=0x04;
MSDelay (10);
P2=0x08;
MSDelay (10);
}
}
sense1=0;
if ((sense2=='1') && (sense1!='1'))
{
for (i=0; i<=2;i++)
{
P2=0x01;
MSDelay (10);
P2=0x08;
MSDelay (10);
P2=0x04;
MSDelay (10);
P2=0x02;
MSDelay (10);
}
}
sense2=0;
}
}
void MSDelay (unsigned int value)
{
unsigned int x,y;
for(x=0; x<1275;x++)
for(y=0;y<value;y++);
}nitish kumar singhParticipantsir
i had purchased a stepper motor in which uln2003A was provided along with it.so it may be unipolar motor.
nitish kumar singhParticipantplease reply sir
nitish kumar singhParticipantThe above program is correct to rotate in clock wise and anticlockwise.I wantt to rotate only two step in each direction according to condtion not to rotate continously.
nitish kumar singhParticipantin both If condition, it is required to correct it or only in one case.
if ((sense2=='1') && (sense1!='1'))
if ((sense1=='1') && (sense2!='1'))
After making correction the led on ULN 2003 blink randomly but stepper motor yet not rotating.
March 10, 2015 at 3:37 pm in reply to: How Pressure Sensor is Interfaced with At89C51 microcontroller #12685nitish kumar singhParticipantThanks for ur suggestion .If possible could you send me exact ckt connection .If you have done any work on it could you tell me which load cell is suitable for my project.
My email id is- [email protected]
March 7, 2015 at 4:30 am in reply to: How Pressure Sensor is Interfaced with At89C51 microcontroller #12675nitish kumar singhParticipantActually i want to place a pressure or Vibration sensor under the track so that when a train came over it then it produce a signal and this signal is sent to microcontroller then close the gate.
IR transmitter and Receiver can not be used because there willbe chance of error such as long animal (like giraffe) can also generate an interrupt signal and close the door.Pressure sensor is more accurate and error free because pressure sensor can be optimized to sense certain range of weight. What you think about my problem and what could I choose as a sensor to detect Train.
March 7, 2015 at 4:16 am in reply to: How Pressure Sensor is Interfaced with At89C51 microcontroller #12674nitish kumar singhParticipantHmm, can u tell me the circuit diagram to interface proximity sensor with At89C51.What are the components are used in it?
-
AuthorPosts