week_11
Output Devices
Propose a final project masterpiece that integrates the range of units covered, answering:
At first, I used the Arudino UNO to control the stepping motor to practice the output drivers. Connection line as shown:
The pin 8 in UNO board connection the IN1 in ULN2003, the pin 9 in UNO board connection the IN2 ULN2003, the pin 10 in UNO board connection the IN3 ULN2003, the pin 11 in UNO board connection the IN4 ULN2003. Then I programed in the Ardino.
#include
const int STEPS_PER_ROTOR_REV = 32;
const int GEAR_REDUCTION = 64;
const float STEPS_PER_OUT_REV = STEPS_PER_ROTOR_REV * GEAR_REDUCTION;
int StepsRequired;
Stepper steppermotor(STEPS_PER_ROTOR_REV, 8, 10, 9, 11);
void setup()
{
}
void loop()
{
steppermotor.setSpeed(1);
StepsRequired = 4;
steppermotor.step(StepsRequired);
delay(1000);
StepsRequired = STEPS_PER_OUT_REV;
steppermotor.setSpeed(500);
steppermotor.step(StepsRequired);
delay(1000);
StepsRequired = - STEPS_PER_OUT_REV;
steppermotor.setSpeed(800);
steppermotor.step(StepsRequired);
delay(2000);
}
This week we’re exploring output devices. So, this week the first I decided to put an RGB LED output devices. To create the schematics, I needed the list of components that I needed for the board. Once I secured the components needed, I could easily choose the correct component from the fab.lib in Eagle to create the schematic. The components I needed were:
This week I did some small mistake, so it took me a lot of times. The first time I laid out the plates and processed them, I found that some parts were not cut in place.
I used the USBtiny board to program my board and I used the Arudino UNO to provide the power of 5V. I used Neil's c code and made file to program the board and saved them in a specific directory inside the Desktop. I opened Git Bash and went inside the directory where the c code and the make file where located. Then, I ran the following commands:
make -f hello.RGB.45. make program-usbatiny