help me

kindly be more specific..give more elaborate detail about what you want what is your expected output voltage you are going to power up your detector by what means.
 

t06afre

Joined May 11, 2009
5,934
This forum do not work this way. We will be more than happy to help you in your work. But in order to help. We must know what you have done so far. And why and how you struggle. A great help for us to help you. Would be if you posted any schematics of your setup and or what code you have.
Good luck
 
Hi,
First you have to decide
1. what are the hardwares you have to use.
2. You have to do schematic diagram according to your peripherals.
3. Choose your programming language.
4. Make the program step by step.
5. Simultaneously test your program.
 

Thread Starter

mehtab102

Joined Jun 21, 2011
62
sorry..
i recently join this site.and the rules were unknown..
thnx for replying
plz tell me 8051 projects on sensor base
waiting for ur reply
 

SgtWookie

Joined Jul 17, 2007
22,230
Since you are new to the 8051, just getting a couple of LEDs to flash could be quite a challenge.

Why don't you start with that as a project?
 

Thread Starter

mehtab102

Joined Jun 21, 2011
62
sir i know that how to make led flashing.
we use setb and clear commands.
on a any port we can make even and odd sequence by 01010101 and 10101010
and many more sequence
respected sir!
i know something about 8051...
just request to tell me intermediate projects...
not basic projects...
waiting for reply
thnx
 

Thread Starter

mehtab102

Joined Jun 21, 2011
62
sir i am not pure new...
i know how to make led flashing
we use setb and clr command for making led on and off.
on a single port we can make even and odd sequence...
by this code mov p?,#10101010
and mov p?,#01010101
 

Thread Starter

mehtab102

Joined Jun 21, 2011
62
sir i am not pure new...
i know how to make led flashing
we use setb and clr command for making led on and off.
on a single port we can make even and odd sequence...
by this code mov p?,#10101010
and mov p?,#01010101
just ant to make intermediate projects wwith the help of u.
you will tell me project name and i will post the project code..
correction will make me king..
 

SgtWookie

Joined Jul 17, 2007
22,230
It is not necessary to make three replies in a row that are almost the same.

These forums are not interactive; it may be hours or even days before you receive a reply.

Since you know how to make whatever combination of outputs high and/or low, why not see about controlling a couple of stepper motors? Unipolar stepper motors will be much easier to control than bipolar motors. If you are going to build some kind of robot, you will need to be able to control such motors.

You cannot drive such motors directly from the 8051 controller; the output pins cannot sink enough current. You will need to use transistors or logic-level MOSFETs to sink the current.

I don't know which controller you have. You need to look in the datasheet and tell us what the maximum source or sink current is per I/O pin, and then what is the package limit for source/sink.
 

Thread Starter

mehtab102

Joined Jun 21, 2011
62
Mov a,#66h
back: Mov p2,a
rr a
acall delay
sjmp back
delay:
Mov r0,#100
m1: Mov r1,#255
m2: Djnz r1,m2
djnz r0,m1
ret
end
 

Thread Starter

mehtab102

Joined Jun 21, 2011
62
Sir here is a problem that i dont know how to connect 8051 with stepper i mean connections to ckeck it out in proteous..
It was a try..
I also want to rotate it complete..360 degree
what i do
 

SgtWookie

Joined Jul 17, 2007
22,230
I have surrounded your assembler source code with CODE tags to preserve the formatting; I have also separated the labels from the code themselves. I have found it very convenient to use branch labels as comment lines to document what the purpose of the labeled point is.
You've used #66h to load into "a" (I suppose a register) which is somewhat meaningless until translated into binary, where #1100110b makes a great deal more sense. If the bits were continually rotated, you'd get a sequence of:
1100110
0110011
1011001
1100110
... etc (if the LSB's rotated bit actually wound up on as the MSB; I don't know 8051 code)

Your source:
Rich (BB code):
	Mov a,#66h
back:
	Mov p2,a
 	rr a
	acall delay
	sjmp back
delay:
	Mov r0,#100
m1:
	Mov r1,#255
m2:
	Djnz r1,m2
	djnz r0,m1
	ret
	end
Assuming that you are using a unipolar stepper (vs a bipolar stepper) you'll need to use transistors or logic-level MOSFETs to sink current from the stepper motors' wires in turn, as the I/O pins of the 8051 will not be able to supply enough current.

You need to tell us what your uC's Vcc is.
You also need to tell us more about the stepper motor that you are using; what is its' rated voltage, and current for the windings.

One problem might be what transistors or MOSFETs to use. I have no idea what might be available to you in Pakistan, but I suspect that you will not have much of a selection.
 

Thread Starter

mehtab102

Joined Jun 21, 2011
62
sir!
m doing my work on keil and check my code in proteous
i m using 8051..
unipolar stepper
'uln 2003
these are availabel in proteous...
i search last time on net some code.
i make their hex. file and load in proteous.
they were running in proteous..
bt i didn't understand code .plz explan this..
only their hex value.that what there purpose to used there..
code is
org 000H

stepper equ P2
main:
mov stepper, #08H
acall delay
mov stepper, #06H
acall delay
mov stepper, #04H
acall delay
mov stepper, #01H
acall delay
sjmp main
delay:
mov r7,#4
wait2:
mov r6,#0FFH
wait1:
mov r5,#0FFH
wait:
djnz r5,wait
djnz r6,wait1
djnz r7,wait2
ret
end
 

SgtWookie

Joined Jul 17, 2007
22,230
sir!
m doing my work on keil and check my code in proteous
i m using 8051..
unipolar stepper
'uln 2003
these are availabel in proteous...
You should post an image of your schematic, preferably in .png format.
i search last time on net some code.
i make their hex. file and load in proteous.
they were running in proteous..
bt i didn't understand code .plz explan this..
only their hex value.that what there purpose to used there..
code is
Rich (BB code):
<snip>
The code you found is faulty. The code you were using before was better.

The "RR A" instruction makes the motor step in one direction.
If you used "RL A" then the motor would step in the other direction.

The entire 8051 instruction set is covered here:
http://www.win.tue.nl/~aeb/comp/8051/set8051.html
 
Top