Building a small railroad X-Ing

I'm building a railroad X-Ing and I need these features:

A stepper motor (not a servo) to lower a barrier (motor: 28BYJ-48 with a ULN2003 controller). If it is activated the motor (with a shaft attached), will turn 90 degrees to the left, and when it becomes deactivated, it returns to its original position (straight up)

While activated it has 2 LED's and 2 buzzers going off simultaneously

How can I write the code so I can control the stepper motor? I know how to code the LED's to flash, but not the stepper motor.

Read Terry's discussion:
http://arduino-info.wikispaces.com/SmallSteppers

A servo would be much easier to use because a stepper motor does not know where it is when the Arduino is first powered up and you will need a limit switch and suitable code to make the motor move to the switch to establish the Zero position.

If the problem is that a servo moves too quickly have a look at the servo sweep example that comes with the Arduino IDE.

If your Arduino will be doing other things as well as moving the barrier you may find the demo Several Things at a Time useful. It also includes servo code and flashing LEDs

...R

I know you said no servo's be we often feel obliged to bring up certain point.

loss of power, the only smart way to run the steppers when they are seldom used, will result in the possible loss of positional awareness.

you will need to have either hard stops on the end of travel or end switches.
something the servo has already.

you needs to allow for the larger power consumption that a stepper needs.

however, sometimes one wants to use a thing to learn about the thing.