using T89C51AC2 to run motor and LEDs

Discussion in 'The Projects Forum' started by lanfear, Dec 22, 2012.

  1. lanfear

    Thread Starter New Member

    Nov 7, 2009
    Basically some time after the holidays I should be starting to learn how to program a microcontroller. However since I have little to do atm, I would like to get a head start on it and buy the items I would need now rather than later.

    I should be getting a board with a T89C51AC2 on it and I would like to connect a motor on it which can go forward and reverse and be able to control the speed.
    I would also like to be able to connect 2 rows of LEDs where if the motor is going forward it would light one row and if it is going reverse it would light the other, but so that it gives a reflection of how fast its going. For example if its going at max speed one whole row will light.

    As I understand it I would need a driver, one for both the motor and the LEDs. My first question is would a dc motor be easier to program than a stepper and also is there anything special I should be looking out for when choosing a driver, besides the current it can handle? Would a L293D be basically be good enough for a small motor powered by the board and would I be able to control a 5V motor or would I need a 12V?

    As for the LEDs I am not sure if it would be possible for me to do. First, if it is possible, would it be hard to program keeping in mind I have little experience coding? second would I still have enough ports available to drive them after the motor, and third I am completely clueless as to what I would have to buy in order to make this.

    Sorry for the many questions and thanks in advance