Monday, 8 April 2013

Attempted to program the controller

My first attempt of the day was to control the stepper motor with the controller. The thought was to supply a square wave to the 'STEP' terminal of the motor driver. I searched the command manual through but was unable to get a solution. I then started trying to use the slot J1 for the servo motor as an input to the driver which I thought should be an Analogue square wave. The wider the pulse the faster the servo turns, whereas the principle of a stepper motor is merely the opposite, the narrower the pulse, the faster the frequency and motor speed.

I moved onto trying to read the voltage from the sensor. I have firstly configured the I/O ports of the extension board, then read the analogue input from port 1 with the code MG @AN[1]. I have used the +12V power supply on the extension board to power the load cell, but the reading is steady despite of the force I apply. I tried to read some other ports and see if I can find out what has gone wrong, however all other ports read 0. I then reset the controller wishing it would help. Unfortunately, after resetting, the total number of available ports had decreased, and port configuration using the command CO had no effect.

No comments:

Post a Comment