help me

Discussion in 'The Projects Forum' started by mehtab102, Jun 21, 2011.

  1. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    i want to make obstacle detector with 8051
    plz help me
    m new with 8051
    plz
     
  2. payal.kellyyy

    New Member

    Mar 28, 2011
    28
    0
    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.
     
  3. MrChips

    Moderator

    Oct 2, 2009
    12,442
    3,361
    Anyone that posts a request with the subject title "help me" does not deserve any help.
     
    KiwiKid likes this.
  4. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,222
    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
     
    mehtab102 likes this.
  5. madhusudan.pigeonsembs

    New Member

    Mar 17, 2011
    23
    2
    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.
     
    mehtab102 likes this.
  6. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    plz tell me 8051 projects....
     
  7. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    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
     
  8. bertus

    Administrator

    Apr 5, 2008
    15,648
    2,347
  9. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    sir!
    i want to make simple rebot
    cz i am new with 8051.
    plz help me
     
  10. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    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?
     
  11. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    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
     
  12. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    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
     
  13. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    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..
     
  14. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    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.
     
  15. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    sir i have atmel 89c51..
    ok sir i will send you the unipolar stepper motor code...
     
  16. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    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
     
  17. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    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
     
  18. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    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:
    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.
     
  19. mehtab102

    Thread Starter Member

    Jun 21, 2011
    62
    0
    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
     
  20. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    You should post an image of your schematic, preferably in .png format.
    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
     
Loading...