JAMDROID Group Seven Kacey Lorton BSEE Brian Parkhurst
JAMDROID Group Seven Kacey Lorton, BSEE Brian Parkhurst, BSEE Anna Perdue, BSEE
What Is It? • Electrically controlled electromechanical system that produces human-like guitar performance. • Uses internal memory or external converted music files to send coordinated commands to motors and solenoids, which control string pressing and picking.
Motivation • Interest in integrating music with electrical engineering concepts • Exploration of an uncommon project theme • Desire to increase knowledge of an familiarity with electromechanical devices
Goals and Objectives • Create characteristic guitar sound through electromechanical, rather than human, performance • Achieve satisfactory timing and coordination of electromechanical devices within a narrower-than-perceptible tolerance. • Acquire and drive devices whose performance will allow for audio playback through a range of common tempos. • Achieve goals with a low-cost, low-power, wall powered solution
Specifications and Requirements • Overall system requirements: Parameter Specification Maximum Note Speed 10 Hz (600 notes per minute) Pitch Range Three octaves (37 discrete pitch levels) Volume Range 8 discrete volume levels
Primary Electromechanical Devices Device Function Solenoid Depresses guitar string to change pitch Stepper Motor Rotates guitar pick to strike string Servo Motor Drives solenoid to select different string; Controls volume of guitar picking
Mechanical Block Diagram
• Base Assembly Guitar Body Assembly • Rests flush with the top of Guitar Body (shown in magenta) • Holds box-like framework that travels orthogonally to the surface of the guitar, to provide dynamic control (shown in Pink) • Box-like framework suspends 6 servo motors, 3 on each side and staggered (Shown in Lime Green)
String Picking System • Stepper motors each have one pick attached to the shaft • One stepper is responsible for one string • Worm gear system (Dynamic Control), one in each corner, which rotate to provide minor vertical position adjustments of the stepper frame (shown next)
Dynamic Control System • The idea: Raise and lower the picks to change how far down past the string they go • The deeper the pick goes, the further the string will be displaced when it is plucked by the stepper/pick • This will allow for different levels of intensity in the playback of a song
Guitar Neck Assembly • Framework that will enclose the guitar neck • Two main bulkheads through which the neck would pass • Two parallel dowels, fixed on the bulkheads • Floor plate to mount servo motors • Solenoid assemblies will be: • Attached to the servos via belts (shown in green) • Horizontally free-moving (frictionless but attached to belts) • Suspended over strings uniformly by grooved wedges, shown in pink
String Selection and Fret Pressing • 12 solenoids (shown in teal, one for • • each fret of the first 12 frets on the guitar neck) Size constraint of the upper frets limits our design to the wider, lower frets 12 Servo Motors (one for each solenoid, responsible for moving it from side to side) This design is in lieu of an array of solenoids (12 frets * 6 strings = 72 solenoids = expensive) Also, movable solenoid alleviates size constraint of solenoids (string-to-string distance of 7 mm at nut, 10 mm at bridge of guitar)
Electrical Block Diagram Work Status: Microcontroller Solenoid Servo Stepper Driver Circuits Power Regulation Power Supply Guitar Computer Guitar Amplifier Purchased Sampling Research Purchased Pre-owned
Picking System – Stepper Motor • We are using bipolar stepper motors to drive the rotation of the guitar picks • The desired motor behavior is to rotate between -30 o and 30 o from the string, traversing 60 o to pick one note • 3. 9 V, 2 -phase bipolar (SY 20 STH 30 -0604 A, Pololu) Specification Desired Value Product Value Minimum torque 102. 3 g-cm 180 g-cm Max length, width 22 mm 20. 2 mm Rotational speed 200 rpm 286. 8 rpm
Example Motor Step Sequence • Full step sequence • Both coils are energized at all times • Pulses must occur in sequence, rather than with constant polarity • For rotation in the opposite direction, the sequence is reversed IA IB
Step Sequence State Machine • We wanted to use two control lines from the microcontroller: - Step - Direction • All transitions occur at the positive edge of the step signal. • The full implementation of the state machine for one motor encompasses two XOR gates and two D flip flops. • The derived input • Da = Dir xor B’ • Db = Dir xor A Dir A B Da Db A+ B+ 0 0 0 1 0 0 0 1 1 1 1 0 1 0 1 1 0 0 0 1 1 1 1 0 0 0 1 1 0 1 0
Stepper Motor Driver Circuit flow: MCU Control Lines -> Logic -> H Bridge -> Motor
String Depression System - Solenoid • The desired solenoid behavior is to apply enough force to depress the string when activated • 5 V D-frame (ZHO-0420 S-05 A 4. 5, Sparkfun) Specification Desired Value Product Value Force 200 gf 140 gf Max length, width 20 mm 12, 11 mm Rotational speed 200 rpm 286. 8 rpm Current Draw 1 A 0. 4 – 1 A Weight 50 g 13 g
Solenoid Driver Circuit • Simple switching circuit • Darlington Pair BJT can handle up to 8 A of current (we need about 1 A) • Flyback diode protects circuit from back EMF
Pulley System- Servo Control • The twelve selected servos • interfaced directly with the microcontroller chip’s twelve dedicated individual PWM GPIO pins • Microcontroller and servo motors share a common ground. • The Servos (MG 90 S, Tower. Pro) require a pulse width modulation voltage of 5 volts. • When the input of 3. 3 volts coming from the microcontroller goes to the tri-state buffer they can output the required 5 volts to the servo. • The MG 90 S will require a voltage step up on the PWM input line. • The 74 VHC 244 FT buffers’ Vcc are tied to the 5 Volt line used by the Servo DC power node. • The 74 VHC 244 FT comes in a surface mount packaging, • Resistors can be tombstone surface mount components, to conserve space.
Dynamic Control • Two servo motors the HS 311, Hitec • They can be tied to the same power, same PWM input control line, and the same ground. • Need to be actuated at the same time and travel the same distance. • This circuit is easy to implement • No separate driver circuit • One PWM line from the microcontroller. • This should not cause any issues apart from the current drawn from the microcontroller.
Brains - Central Microcontroller • Tiva C Series TM 4 C 123 G • Built in PWM channels • 32 -bit ARM Processor • Familiar CCS software
MCU Program Structure • Lowest level functions: • Change solenoid state (simple on/off) • Change Servo PWM value (encodes position) • Activate hardcoded stepper motor pulse sequence (one stroke) • Higher level functions: • Note parameter -> device command converter • Timing optimization
Software/ Firmware Block Diagram
What is MIDI? • Musical Instrument Digital Interface, or MIDI, was developed in 1983 as a means for instruments and computers to communicate and control one another. • Most of the data in a MIDI file is dedicated to the different instrument tracks and their events • Events include Note Off, Note On, Note Aftertouch, Program Change, and Pitch Bend • Each event contains note pitch, velocity (volume), and start and stop time stamp values • Events are encoded in chronological order, with a field indicating the time delay from the previous event, with the lowest value being zero, meaning the event should occur simultaneously with the previous event.
Software Summary • The goal of the desktop application (C++) is to parse a MIDI file into its sequence components • Our baseline system only needs pitch, volume, and timing data – the rest of the data can be thrown out • Shown: Relevant information on a five note sequence • Once the MIDI information is processed, the entire sequence packet is sent to the MCU which will determine device commands Sequence Title, Beats Per Minute = 60, Time Signature = 4/4 Number of items in Sequence = 6 Measure Note (0 -127) Intensity Duration Aftertouch 0. 00 0. 25 0. 50 0. 75 1. 00 2. 00 60 (Middle-c) 62 64 65 67 100% 100% 0% Quarter Whole Rest No No No Modulatio n No No No
Frequencies • MIDI has 128 different notes • Some of them line up with available notes that can be played by our apparatus • The lowest frequency available on the guitar, assuming a standard tuning of E, A, D, G, B, and E in that order • MIDI Sequences begin at the Scientific Notation pitch of C 1, which is a frequency of 32. 703 Hz. This is below the lowest available frequency to be possibly played on the guitar. • The maximum note being one octave above E 4 (12 frets meaning 12 half steps meaning one octave), E 5 is our maximum frequency to be played. This note is 659. 26 Hz. String Frequency 1(E) 329. 63 Hz Scientific Pitch E 4 2(B) 246. 94 Hz B 3 3(G) 196. 00 Hz G 3 4(D) 146. 83 Hz D 3 5(A) 110. 00 Hz A 2 6(E) 82. 41 Hz E 2
Mapping Module Example • MIDI Sequence Notes will be given equivalent positions on the guitar • If a note can be played on an open and available string, it would be convenient in all aspects to simply pick that particular string. • Also to be converted is the measure value to a timestamp value, by taking the beats per minute and measure and combining them, taking into account the time signature as well, into a point in time for our convenience, with the beginning of the sequence being time t = 0. 000. Sequence Title, Beats Per Minute = 60, Time Signature = 4/4 Number of items in Sequence = 6 Measure Note (0 - String Fret Whole/Hal Duration 127) f/Quarter/e tc Time t End Note Time 0. 00 0. 25 0. 50 0. 75 1. 00 2. 00 0. 000 0. 250 0. 500 0. 750 1. 000 2. 000 Inf. 60 62 64 65 67 X 2(B) 1(E) X 1 3 0 1 3 X Quarter Whole Rest 0. 250 Infinity
Converted Mapping Module • Example sequence, shown with conflicts • Warning in red • Fret Conflict; two notes on the same • • fret at the same point in time This simple G – Chord cannot be implemented in our design The Higher note, 1(E) on fret 3 can be moved to string 2(B), on fret 8 In yellow is a note that is beyond the range of the playable frets This note can be taken down an octave and played
Firmware Summary • Once the MIDI-converted Note Sequence Packet has been sent to the MCU, It must be turned into sequential and simultaneous Driver commands • The microcontroller will see a list of tasks to perform in a timeline • For this to happen, we need to have a few data classes
Devices in state/position Value Component • Servo motors will need 6 different states, one per position above a string on the guitar Solenoids only have two states, on or off Stepper motors have many possible states, 0 (no action) all the way up to the maximum speed we can achieve Different mechanical actions take different lengths of time to complete Servo Motor 1 Servo Motor 2 Servo Motor 3 Servo Motor 4 Servo Motor 5 Servo Motor 6 Servo Motor 7 Servo Motor 8 Servo Motor 9 Servo Motor 10 Servo Motor 11 Servo Motor 12 Solenoid 1 Solenoid 2 Solenoid 3 Solenoid 4 Solenoid 5 Solenoid 6 Solenoid 7 Solenoid 8 Solenoid 9 Solenoid 10 Solenoid 11 Solenoid 12 Dynamic Control Servos Stepper Motor 1 Stepper Motor 2 Stepper Motor 3 Stepper Motor 4 Stepper Motor 5 Stepper Motor 6 Reference Designation SER 1 SER 2 SER 3 SER 4 SER 5 SER 6 SER 7 SER 8 SER 9 SER 10 SER 11 SER 12 SOL 1 SOL 2 SOL 3 SOL 4 SOL 5 SOL 6 SOL 7 SOL 8 SOL 9 SOL 10 SOL 11 SOL 12 DYN Possible Values STEP 1 STEP 2 STEP 3 STEP 4 STEP 5 STEP 6 0 through Max Speed 0 through Max Speed 1, 2, 3, 4, 5, 6 1, 2, 3, 4, 5, 6 1, 2, 3, 4, 5, 6 Up, Down Up, Down Up, Down Low, High
Time-base list • A note is given a slot with all of the necessary commands required to implement that note • Notes in the future have to be considered before they need to be played, as servos have a noticeable time delay to change position • The advantage of splitting is that there is inherent delays in moving objects over variable distances, which would need to be calculated based on previous positions • An example of what that would look like is…
Timestamp • Each type of Mechanical device would get its own list with time-based events • Timing could be more precise where required • One issue could be debugging unsynchronized events Timestamp +0. 000 +0. 250 +0. 500 +0. 750 +1. 000 Stepper STEP 2 STEP 1 Action Pick Pick Timestamp -0. 250 +0. 275 +0. 525 Servo SER 1 SER 3 Action Move to 2 Move to 1 Timestamp Solenoid Action -0. 050 +0. 249 +0. 510 +0. 740 +0. 999 +1. 999 SOL 1 SOL 3 ON ON OFF OFF
PCB Design • No real size constraint on our PCB • We will enclose our PCB and power supply inside a Metal ‘Bud Box’ • Large wiring harness going from PCB to guitar apparatus • Used Cad. Soft Eagle for PCB implementation • 95% complete with schematic • Starting Board Layout
PCB Schematic and Board Layout
Power Supply • SE-350 -24 TRX Electronics Specificatins Input Voltage 115/230 VAC Output Voltage 24 V Output Current 14. 6 A Max Power 350 W • This product offers protection for short circuit, overload, over voltage, and over temperature Component Manufacturer Power Supply Stepper Motor Servo Motor (Pulley System) Servo Motor (Dynamic Control) Solenoid TRC Electronincs Pololu MCU TIVA Part Number SE-350 -24 Rated Voltage 24 VDC Rated Current 14. 6 A 3. 9 VDC 0. 6 A Tower Pro SY 20 STH 300604 A MG 90 S Hiltec HS-311 4. 8 -6 VDC Spark. Fun ROB-11015 5 VDC ROHS TM 4 C 123 GH 6 PZ 3. 3 VDC 19. 7 m. A 4. 8 -6 VDC 7. 4 -7. 7 m. A/idle 160 -180 m. A no load operating 0. 5 A
Power Distribution
Power Regulation Schematic • LM 25117 • Synchronous buck controller intended for step-down regulator applications from a high voltage • The operating frequency is programmable from 50 k. Hz to 750 k. Hz. T • Features • • Thermal shutdown Frequency synchronization Hiccup mode current limit Wide Operating Range from 4. 5 V to 42 V
Power Regulation • TPS 62095 RGT • Step down Converter
Power Regulation • LMR 10515 Y • Step-Down voltage regulator
Finances Parts Vendor Part Number Price QTY Total Solenoid Spark. Fun ROB-11015 $4. 95 12 $59. 40 Flyback diode Digikey 641 -1311 -1 -ND $0. 11 12 $1. 32 NPN Darlington Pair Digikey TIP 102 TU-ND $0. 91 12 $10. 92 BJT base resistor Digikey CF 14 JT 2 K 00 CT-N $0. 08 12 $0. 96 Stepper Motors Pololu 1204 $17. 95 6 $53. 85 H Bridge IC Digikey 296 -29434 -2 -ND $2. 73 6 $16. 38 D Flip Flop IC Digikey 296 -8257 -5 -ND $0. 52 3 $1. 56 XOR Gate IC Digikey 296 -8375 -5 -ND $0. 49 3 $1. 47 Servo Motors (Pulley system) Tower Pro MG 90 S $8. 23 12 Buffer Driver Digikey 74 VHC 244 FT(BE) $0. 49 Servo Motors (Dynamic Control) Hiltec HS-311 Power Regulator Texas Instrument LM 3150 Parts Vendor Part Number Price QTY Total Power Regulator Texas Instrument TPS 54336 $2. 26 1 $2. 26 Power Regulator Texas Instrument TPS 61725 $1. 44 1 $1. 44 Power Regulator Texas Instrument LM 25117 $4. 30 1 $4. 30 Power Supply TRC Electronics SE-350 -24 $55. 05 1 $55. 05 $98. 76 Building Material ------------ $50. 00 ------ $50. 00 2 $0. 98 PCB board ------------ $50. 00 1 $50. 00 $10. 02 2 $20. 04 Driver Belt Trapezoidal Tooth Urethane 1679 K 634 $1. 39 12 $16. 68 $1. 42 1 $1. 42 Bud box ------------ $20. 00 1 $20. 00
Milestones AUGUST 1 -8 9 -15 16 -22 23 -31 SEPTEMBER 1 -5 6 -12 13 -19 20 -26 27 -31 OCTOBER 1 -9 10 -16 17 -23 24 -28 November 1 -9 10 -16 17 -23 24 -31 December 1 -5 6 -13 Order Parts Mechanical testing for string plucking sub-system, work on code Mechanical testing for String Depression sub-system, work on code Work on programming code, PCB Design Continue program, and PCB Design Code Testing; finalize schematics Debug; order PCB Board Debug Testing Debug Assembly of systems Interface Testing Work on paper and presentation Presentation
Division of Labor System Anna Brian Dynamic Control X Electrical Enclosure X PCB X Power X Pulley X Servo X X X Stepper Structural Frame Kacey X Software Solenoid ANNA X X
Progress Report ANNA Series 1 Prototype Testing Series 1 Research Design 0% 10% 20% 30% 40% 50% 60% 70% 80% 90%
Problems
Questions?
- Slides: 46