WEEK 9 - OUTPUT DEVICES

this week i am planning to start with my final project.i need to find and test the motor need to be used for my #SLOT-MACHINE.options in mind are stepper motor or dc motor with encoder. i am building a motor driver board ot test both dc and stepper, make a comparison about it this week

assignment

individual assignment

  • add an output device to a microcontroller board you've designed, and program it to do something
    group assignment:
  • measure the power consumption of an output device

about the motors

dc motor

A DC MOTOR IS AN ELECTRIC MOTOR THAT USES A DIRECT CURRENT TO GENERATE TORQUE. IT HAS A ROTOR THAT SPINS INSIDE A STATOR, AND THE ROTATION IS CAUSED BY THE FLOW OF ELECTRICAL CURRENT THROUGH THE MOTOR.

brushed-vs-brushless-motor-1-1200x579-960w.png.jpg

difference between brushed and brushless dc motors

dc motors are more EFFICIENT compared to stepper motors.

stepper motor

stepper motor is one most identifiable motor i saw on on fablabs. because they are avidly used in cnc and 3d printers. they are heavy and high TORQUEY can CONTROL steps or angles.

IMG_7890.jpg

IMG_7892.jpg

BUT STEPPERS CAN'T REVOLVE FAST AND AREN'T EFFICIENT.

making the board

i am using two a4953 with a attiny 1614 to make a MOTOR DRIVER board that can control both dc and stepper motor. thsi design is inspired from #NEILGERSHENFELD board

hello.stepper.bipolar.44.jpg
neil's hello stepper board

i made a schematics usig kicad which documented in WEEK 8 - ELECTRONICS DESIGN.

Pasted image 20240402122903.jpg

final schematics

then i routed the board.while routing the board i have give 0.6mm traces for 12 v lines to avoid potential short circuits and electrical breakdown.

Screenshot 2024-03-26 at 3.20.26 PM.jpg

in order to do this you need to add sizes in PREDEFINED sizes in board settings.

Screenshot 2024-03-26 at 3.24.55 PM.jpg

Screenshot 2024-03-25 at 8.10.04 PM.jpgbill of materials exported from kicad

after routing i milled the board after several tries of not getting milled properly because of bed level issues. milling is documented in WEEK 4 - ELECTRONICS PRODUCTION

IMG_7885.jpg
milled board. i named it "dumotod"

i made a mistake by removing pad under a4953 chip to ease routing but now i have to insulate the tracks under it.

IMG_7887.jpg
insulating track to avoid shorting

and i soldered the board.

IMG_7889.jpg

connecting the stepper

SerialUPDI
UPDI programming for Arduino using a serial adapter
Based on pymcuprog, with significant modifications
By Quentin Bolsee and Spence Konde
Version 1.2.3 - Jan 2022
Using serial port /dev/cu.usbmodem413B84523 at 57600 baud.
Target: attiny1614
Set fuses: ['0:0x00', '1:0x00', '2:0x02', '5:0b11000100', '6:0x04', '7:0x00', '8:0x02']
Action: write
.10/tools/libs/pymcuprog/serialupdi/link.py", line 44, in init_datalink
    raise PymcuprogError("UPDI initialisation failed")
pymcuprog.pymcuprog_errors.PymcuprogError: UPDI initialisation failed
Failed to burn bootloader: uploading error: exit status 1