Updates

Design Process Link to heading

Here is a chronologically updated design update. This will be in addition to our final project writeup. This is a good way to see where we find errors, make adjustments and document our progress through our failures.

Initial Design Update March 1st Link to heading

Here we are trying to create a way for us to utilize a two-magnet system in order to create the force necessary to drive a tool head. In the picture shown, we are seeing where we would place the magnets and electro magnets (square and rounded holes respectively).

Note: here, I made a 2-magnet version of our linear motor. However, I realized once I did the math that I would need a third magnet to even out the power and force cycles. Again, as mentioned before in the theory section, I think that four magnets may be optimal for even force distribution and smoother velocity curves, but logistically and for applicability, we will stick to three magnets.

Additionally, in order to validate the taxonomy of the project, we will be utilizing Jake Read’s Clank Project and cleat system.

This will serve as our base to mount our tool.

The backside of our linear motor carries the same pattern as Jakes cleat. This will allow us to utilize other soldering irons if we want to bring on multiple solder patterns.

- Intermediate pause in final project updates - Link to heading

Here, we had to take some time for some personal issues. Additionally, we took these few weeks to take and create our group presentation on additive manufacturing.

Design Updates Link to heading

Updated March 23rd Link to heading

Large Update - here we made quite a few updates in both the design over the Sloan Intensive Period (SIP) and Spring Break.

Summary:

  • Transferred everything to PTC OnShape (from Fusion360)
  • Introduced 3rd electromagnet
    • It will allow us to prove the hypothesis that we only need 2 electromagnets
    • It will give us more control regardless if hypothesis above is wrong
  • We’ve made the design directionally independent.
    • Symetrical against the X axis.
    • Allows the PCB or the tool head to be mounted on either side
    • Both sides use Jake Read’s clank footprint (note this will force our PCB to use a similar footprint)

CAD Update Link to heading

Here we updated our CAD like the following. Note our carrier will not be made transparent - it is transparent in the CAD to show where the EMs will go.

EDA - Board Link to heading

Here is the area of the project where I am weakest on. In this case, we took inspiration for our EDA using this example Arduino sketch for a magnetically floating object.

A few differences that we would like to incorporate in our design

  • Our processor is a ESP32 WROOM- no real reason for this except it is what I have on hand. Note, I believe this could be done with less expensive chipsets and I do not need the faster processor speeds or a larger number of GPIO pins. However, the added WiFi may be handy for upgrading the applicability of our motor.
  • More magnets - we will be using 2-4 magnets in our design all with the same amount of max force (from the EM).
  • Reverse current - unsure how we specifically will accomplish this but unless we use a dedicated IC, we may have to use a series of diodes and FETs (as switches) - with respective capacitors and resistors.
  • Hall Effect Sensor - this would be a great way to detect location of precisely where we are along the linear rail.

Electronic Design Process Link to heading

A few challenges that we need to get through. Here are a few that have been identified at this stage:

  • Variable force magnet through variable current control
    • Control current amount (EE)
    • Reverse current (EE)
    • Timing of current control and current reversal (CS)
  • Position reference (encoder)
    • rotary encoder mechanically translated to linear motion (EE/ME)
    • magnetic sensor using Hall Effect (EE/ME/CS)
    • gyro/accelerometer using readings to determine position from known point. (EE/CS)

Skill identifiers EE - Electrical Engineering CS - Computer Science ME - Mechanical Engineering

Variable Magnetic Force - Electromagnets Link to heading

Firstly, variable magnetic force. Although we can move the linear motor by turning the electromagnets (EM) off and on, we want to be extremely deliberate with the amount of force applied. There are a few ways that we can tackle this issue. Although it is “technically” feasible to do this by changing the mechanical properties such as number of turns and area, the most practical way to do this is to change current. However, there are a few techniques to do this.

MOSFET - use a MOSFET and gate to change the amount of current drawn. Variable Resistor - a digital variable resistor would change current (with the same voltage) based on Ohm’s law. In this case, we will most likely go with a NPN FET based on some preliminary sketches.

Digital Potentiometer/Rheostat (DGTL POT - “Digi Pot”) - Here a normal potentiometer is again acceptable (one where the resistance is changed by hand), however, it is again, impractical for our purposes as we would need to change the value of our resistance on the order magnitude of milliseconds and utilize a control methodology on the backend.

In this case, there is already a setup where we can use an OPAMP to maintain voltage, and then utilize a variable resistor on the back side in order to sustain voltage. Here, we would like to expand our entire board to operate both on 3.3V and 5V; however, we will optimize our setup for 5V (as that is what our electromagnets are most strongly weighted for).

Since we know the operating range for most microprocessors is somewhere between zero mAs and 500mA-1A of current, that means we should aim for the lower side of the top of our maximum current (for a little safety buffer). Using Ohms Law, this means that our total current resistance should be 5,000ohms to around 10ohms (10-5K).

One of the fundamental issues here is that controlling the resistance of the flow in order to control the current is based on a primary assumption: constant voltage. Here, we can utilize an OPAMP to maintain the same amount of voltage throughout the system.

We can see that the op amp is tied back around after the resistor. This will ensure that the voltage past the potentiometer remains the same as the one before it. This is critical to control the current flow past digital potentiometer (digi-pot). We took the basic schematic of the voltage follower below and applied it to our design.

Current Reversal Link to heading

There are quite a few ways to do the current reversal. However, the issue remains that not all of the components in our circuit are reversible - really, none of them are except the resistors and wires themselves.

The few primary ways that we can accomplish the current reversal:

  • H-Bridge
  • Current Mirror

There are a few reasons we did not utilize a current mirror. Firstly, logistics - we dont have one on hand and they are less available circuits compared to h-bridge ICs; this is mostly due to the necessity of h-bridges in stepper-motor control schematics. Generally, the costs are comparable, but the we hope that this design is built to be more accessible.

Finally, due to the op-amp placed earlier to control voltage as well as certain nuances in the digi-pot, we may have to change the design in order to incorporate digital switches.

Note: in the above diagram, we may test out replacing one of the switches (SW1 and SW2 respectively) with diodes. This may allow us to do a few thing simultaneously: integrate an LED diode to see when certain motors are powered, incorporate a resistance required to keep us within operating current, all while simultaneously preventing back flow current (protecting our circuit).

Update March 28th (Spring Break Work) Link to heading

During this update, we learned a few things that are critical mistakes in designing our part based on the electromagnet that we are using.

EM Redesign Link to heading

TDLR: Our magnet needs around 50-100mA to be effective. Additionally, the metal housing is affecting the effectiveness of our magnets; our rail magnets are more attracted to the metal housing than they are to the electromagnet part of our magnet.

Here we are testing our current EM with our power supply.

Metal Housing Link to heading

Easiest Fix - buy pre-wound coils without a metal housing. Note the below EM has a metal core but I am hoping that it should be less effective than the entire metal housing. Alternatively, we can replace the core with a 3D printed plastic one (hopefully).

![[Pasted image 20240329132147.png]] < New Coils>

![[Pasted image 20240329132201.png]] < Old Coil with metal housing >

Note with the new coils being 8mm smaller (27mm old vs 19mm new), this means we get a little more room to play with on the toolhead.

DigiPot Current Limiter Link to heading

This is a little more complicated and requires a bit of adjustment with our digital potentiometers. Firstly, we need to find our maximum rating for our digipots.

![[Pasted image 20240329132635.png]] For our MCP 4017 chip, we can use the 25mA value from our technical specs. However, just to keep it safe and within our output clamp current, we will use the more conservative value of 20mA. This means that we need 3 digipots in parallel to get this working.

Just to keep the board simplified, we will utilize two digipots in parallel. After doing the initial EDA (seen below) we can see that we quickly run out of room for our wire placement. Since we are prototyping initially, I want to keep the board simplified and one sided (mostly) until an alternate method is required.

![[Pasted image 20240329142059.png]]

We will first validate the control of the digital potentiometers before continuing onto increasing the fidelity of our magnets.

Here is our preliminary board to check changing current at the end points.

Here is a little it different where we utilize a few jumper cambles with our Design Rules Check (DRC) due to the limitations of our machine. We may have issues with multiple potentiometers.

I always love the CAD display to show how the board looks

Update March 30 Link to heading

Issues: Link to heading

  • DigiPot Pitch - too small to mill (< 1/64th in in width for wires)
  • Manufacturing limitations
    • Alternate manufacturing methods - photopositive PCB reactive, photo limiter “prints”, outsourced PCB manufacture

Updates: Link to heading

  • new electromagnet (remove internal metal component)
  • redesign new electromagnet housing
  • testing MOSFET control for current
    • need to redesign schematic for current reversal.
  • tested with and without steel insert in our electromagnet

Redesign with MOSFET Link to heading

  • Utilize PWM to control gate
  • Use as a Gate Drive Transformer and an H bridge to create a galvanically isolate switching source for multiple MOSFETs.
    • (not my drawing. Source: https://www.youtube.com/watch?v=8swJ_Bnsgl4)
    • Note: this feature may not be needed. We may be able to get away with not worrying about voltage decay with the MOSFETs as we can assume near-symmetry in decay from the motors.
    • This would allow us to run current back and forth between the mosfets (in multi direction accross the load). We can compare this method of switching and an H-bridge methodology suggested by Jake Read.

Here, we tested the MOSFET example. We are getting minimal magnetic force from the electro magnet but the concept holds true that we can use the MOSFET to control it. When we run our DMM, we get a average current of 70-80mA. I think this proves that we want about double that amount to overcome our friction coefficient of our entire rail system.

We tried replacing the current resistor tied to the drain with lower resistor (200 > 100 ohm). However, that kept relatively the same amount of current within electromagnet.

Here, we got put two MOSFETS in parallel and were able to achieve around 180mA. We removed the 200k resistors and now pull around 250mA.

Note: even with running two MOSFETs, it does run hot. We may have to utilize heatsinks in order to cool the MOSFETs ()

We wrote a code, validating with a digital multimeter, that the MOSFET can control the current (near) linearly.

New Design Updates Link to heading

PNP and NPN mosfets

Here is a new board (two sided). This will allow us to control all four electromagnets simultaneously without using an IC. However, a few issues we notice is that there are alot of requirement

https://github.com/simplefoc/Arduino-FOC?tab=readme-ov-file