hi, i want to use gsm to move stepper motor by using arduino as interface. which mean i send sms to gsm module -> gsm module give instruction to arduino to rotate stepper motor 90 degree -> motor rotate 90 degree. is it possible and how to do with the coding?

First, get to know your components and the libraries that come with the arduino. Scour the internet for GSM samples, or simple search for some on the forum. Second instead of jumping right into with a stepper motor, write a simple code that uses LEDs and a simple code to rotate a stepper motor. You may need some way of monitoring or tracking the position of the stepper motor, because they rotate continuously.

Do you need to use a stepper motor or can you use a servo? Servos have a library already for use with samples.

your best bet is a locked servo, because as I said before, a stepper motor rotates continuously when power is applied. you can however control the rotation with short bursts, by timing how long the servo takes to rotate to fully open and to fully closed and put those times into your code.

I haven't encountered any stepper motors that do this. In my experience, stepper motors take a step when they are told to - hence the name. You may be thinking of ordinary DC motors that run whenever power is applied.

In this case the requirement seems to be to operate a latch mechanism and I would have thought that a servo or solenoid giving positive positional control would be the simplest approach.

I only provide help via the forum - please do not contact me for private consultancy.

I meant a sequence, he needs to figure out the sequence to make it rotate 90 and then back.I know if 1 pole is energized it will rotate to align with that pole, but I may take him a few rotations to fully lock the door.

your best bet is a locked servo, because as I said before, a stepper motor rotates continuously when power is applied.

It does not. A stepper motor steps when it is told to step. It steps exactly once. The stepper driver needs to set the state of 4 pins right to make that happen. The exact state of the pins to produce a step depends on which set of coils is powered currently. That is why the control of a stepper is generally offloaded to a stepper motor controller. Well, that and the high current/high voltage needs of a stepper motor. Tell the controller to step, and it steps. Once.