Inqster - The re-Aw...
 
Notifications
Clear all

Inqster - The re-Awakening

52 Posts
5 Users
19 Reactions
1,280 Views
byron
(@byron)
No Title
Joined: 7 years ago
Posts: 1276
 

@inq

Thats a good comprehensive list of resources, and I'll stash those links for future use.  Its a very substantial project you are attempting which should keep you out of mischief for a while.  

I expect you may have, or are intending to, check out the performance of those wheels on paddock ground before proceeding too far along the road with that design as a sanity check.  My own 4 wheeled bot of roughly 35cm x 30cm gets tossed around a fair bit in a fairly flat field, though rabbits and moles do their best to ruin it. 😬  

As you allude to, if one wants a self balancing bot, then theres loads of examples to pick and all should work with a bit of tweaking. One can go a further step of allowing AI into your code editor, and I presume then sit back, give an occasional voice prompt, and end up with a ready made masterpiece.  But why even do that, well, just go buy one.   So yes, my approach will be trying to work it out and discovering it for myself.  This is my motivation for having a go. Its all been done before, but not by me and I will have to guard against making  it too easy by following ready made code or I will probably loose interest and give up on this hobby programming malarky and spend more time in my woodworking workshop, or something like that. 

Having said that, its good to have a peruse of the docs and video's in your links as it help formulate the direction on where I want to go in my evening playtime bot venture.  😀

 


This post was modified 4 weeks ago by byron

   
Inq reacted
ReplyQuote
Inq
 Inq
(@inq)
Rocket Scientist or Space Cadet
Joined: 4 years ago
Posts: 2051
Topic starter  

Posted by: @byron

Its a very substantial project you are attempting which should keep you out of mischief for a while.  

Yeah!  That's what my wife thinks.

 

Posted by: @byron

But why even do that, well, just go buy one.   So yes, my approach will be trying to work it out and discovering it for myself. 

I think that's the best reason in the world.  It's not like we're going to invent something or write a doctoral thesis.  

BUT... Interestingly this came across my news feed this morning.  If its right, we'll be bullet proof from Dementia and Alzheimer.  Maybe even as good as a Taxi Driver 😎 https://theconversation.com/taxi-drivers-rarely-die-of-alzheimers-how-complex-mental-maps-and-spatial-reasoning-protect-your-brain-286650?shem=dsdf,sharefoc,agadiscoversdl,,sh/x/discover/m1/4

 

Posted by: @byron

My own 4 wheeled bot of roughly 35cm x 30cm gets tossed around a fair bit in a fairly flat field, though rabbits and moles do their best to ruin it. 😬  

I passed over this initially, but something about it nagged in the back of my mind.  You are totally right, outside, in the real world will be a total nightmare for a self-balancing robot.  Every bump, jump, dip, and slip will throw the accelerometer and gyroscope data wonkers!  Even with things like PID, it is still based on some very strict fundamental Physics.  I don't think I've seen any of the cookbook versions handle anything significant. 

Which leads me to believe the only version that has a chance for my scenarios that I'd like to achieve entails using the ANN and letting it learn to deal with all kinds of scenarios.  Physics be damned! 🤩 

Thanks @byron!  I think I would have started with PID and spent a huge amount of time, tinkering with it on flat, smooth surfaces, building lots of functionality that would have face planted the first time in the yard.

Inq



   
ReplyQuote
robotBuilder
(@robotbuilder)
Member
Joined: 7 years ago
Posts: 2571
 

@inq 

... Interestingly this came across my news feed this morning. If its right, we'll be bullet proof from Dementia and Alzheimer.

Use it or lose it. Neurons that fire together wire together. Some taxi drivers still get dementia so it isn't the entire story.

"Dementia is an umbrella term for a decline in mental ability severe enough to interfere with daily life, while Alzheimer's is a specific brain disease that causes 60% to 80% of all dementia cases. Put simply, all people with Alzheimer's have dementia, but not everyone with dementia has Alzheimer's."

 

While googling for self balancing robots that could stand up if they fell over I came across this crowd funded project. I wasn't sure if it was real but AI said essentially it appears to be real.

'So if you were wondering whether the impressive videos are entirely fake, the answer is no—there is strong evidence that Beni is a genuine robot, although some promotional footage may naturally show it under ideal conditions."

I think they used reinforcement learning as part of its development.



   
Inq reacted
ReplyQuote
Inq
 Inq
(@inq)
Rocket Scientist or Space Cadet
Joined: 4 years ago
Posts: 2051
Topic starter  

@robotbuilder 

Beni, pretty cool. 

I wonder what they use that is strong and fast enough to make it jump... if its all motors or some kind of pre-loading of a spring and releasing.  



   
ReplyQuote
Inq
 Inq
(@inq)
Rocket Scientist or Space Cadet
Joined: 4 years ago
Posts: 2051
Topic starter  

I've been discussing, at length, with AI (Gemini) my design of powering.  As I've caught AI making mistakes and simply contradicting itself in the same session, much less over multiple sessions, I'd like to bounce this one off anyone more adept at the issues.  (@davee, I'm sure, but others may have experience).

Here was my baseline.

  1. I plan to use battery cartridges I use for yard maintenance.  They are 20V (increments of 5 cell LiIon).  I haven't decided on size I need, but will determine that once I start getting a handle of real-world power utilization.  I want about 8+ hours of awake time with maybe 4 hours of run time and maybe 1 hour of hard running time.  The batteries come in 2, 4, 6.5 and 8 Ahr.  Currently, I'm liking using two in series for a 40V system to give the best balance keeping, acceleration and top-end speed.  It also should reduce the overall  (average) current running through wires.
  2. I plan on having a pretty long length between steppers and electronics.  ~36" or 1m.
  3. Power the electronics from the same 40V pack.
  4. AI says my choice of the Accel/Gyro LSM6DSV (IMU) is very good, but is susceptible to RF.  I asked which is better, having the static 40VDC travel the 1m length and have the stepper drivers at the steppers or have the driver near the battery and ESP32-S3 (MPU) and have 1m long pulsed 40V.  

Here after multiple hours of interaction (actually kind of fun brain-storming with AI).  Going from batteries to steppers.

  1. Preferred the 40V solution per my requirements for powerful correction to balance and high voltage to overcome Back-EMF at speeds over 500 rpm.
  2. At first it suggested some pretty expensive voltage regulators.  After going around and round several times with what I already have, it suggested.
    1. Using LM2596HV to handle the 40V down to 5VDC.  It said these are RF noisy, and not real efficient for this big of a step down.  I'm ok with the efficiency, but the noise will corrupt the IMU.  The MPU will use its own 5V to 3.3V converter for its power needs.
    2. From the noisy 5V line power a AMS1117 LDO, to have a separate 3.3V clean line strictly for the IMU.
  3. LDO as close to the MPU so the SPI lines are as short as possible.  I'll have them less than 10mm and powered by the LDO.
  4. The logic lines to the DRV8825 stepper drivers will also be short if not on the same circuit board.
  5. The 40V connected to the drivers will have a 100 uF, 100V capacitor across its VMOT and GND.
  6. Running the 4 wires to the stepper 1m away, it suggested to twist each pair of coil wires independently, then twist those to reduce RF noise.  It suggested if I was real anal about it, I could also wrap copper mesh as a Faraday cage to eliminate RF.  I prompted about using Aluminum Foil instead and it said "Absolutely" (love it when it says Absolutely) I could wire and ground it at the MPU side.
  7. Also suggested a "Star Grounding" pattern.
  8. Also suggested a 10kΩ resistor routing to the driver's Reset/Sleep pins.  It keeps the pins safely pulled HIGH but blocks high-frequency electrical switching noise from traveling backward into the ESP32’s delicate 3.3V processor rail.

All these precautions are going in now since I'll eventually be using lots of other noise makers (WiFi, Bluetooth) and noise sensitive components I2C sensors and Serial GPS.

If anyone sees any problems or downright mistakes of AI, I'd appreciate a heads-up.

Thanks,

Inq



   
ReplyQuote
(@davee)
Member
Joined: 5 years ago
Posts: 2055
 

Hi @inq,

   I have only glanced at your description, and I haven't actually done anything like it, am all too conscious that doing something for real often displays something 'obvious' that I hadn't understood or considered beforehand, so please treat any comments with a large dose of scepticism, as they may be total rubbish.

re: I plan on having a pretty long length between steppers and electronics. ~36" or 1m.

I get the impression that your research suggested you 'minimise' (A) length of wire from source (battery) to stepper motor driver chips, and you maximise (B) length from stepper motor driver chips to motors. Intuitively, (with NO practical experience of this particular case), this feels completely the wrong way round!

My 'thinking' is that ideally (A) will carry an "almost" constant current flow as the power input to the stepper driver chips should have sufficient capacitance attached (and possibly other filtering).

See DRV8825 Data sheet  https://www.ti.com/lit/ds/symlink/drv8825.pdf?ts=1786768210984 :

 

image

Which I interpret as saying, that the "Parasitic wire inductance" is an unwanted impedance to rapidly changing current flows arising from the PWM action of the driver chip, that will try to prevent some of the voltage reaching the chip. This may be mitigated by adding sufficient capacitance to the power input of the chip, to act as a 'charge reservoir' to maintain the voltage.

(On most computer related PCBs, I guess 90+% of the capacitors are employed for this general purpose of being a charge reservoir that holds the voltage at that point almost constant, whilst the circuit rapidly changes the amount of current demanded from elsewhere.)

By contrast, the outputs from the driver chips are driving a massively more inductive loads, the motor coils.  In this case, the motor coil inductance is being used for the vital positive reason of controlling the current flow through the coils by rapidly PWM switching the current, in a manner reminiscent to that used for a buck converter voltage regulator. (eg LM2596 you mention).

Whilst the power lines to the driver chip are still likely to be 'noisy', it is possible to add capacitors, and possibly other filters, to quiet them down, and help them do the intended tasks. By contrast, the driver output lines will act as aerials to transmit the current switching noise, far and wide, if they are of significant length.

----------

The TI data sheet didn't appear to suggest any filtering additions to the driver coil outputs. 

TMC2209 data sheet https://www.analog.com/media/en/technical-documentation/data-sheets/TMC2209_datasheet_rev1.09.pdf

suggests extra components as an 'enhancement'

image

I am only mentioning this 'enhancement' as a possible rabbit hole to check out, as I haven't delved into it yet.

But note that this is not a get out of jail free card, for making these leads longer than necessary.

-------------

As 'possible' evidence that I am making a huge mistake, I note that common cheap 3D printer controller cards have a short connection to input of the driver chips, since they are usually soldered or plugged into the same card, with a relatively long leads to the motors, but I suspect this is a combination of economics, relatively low power, slower motor speeds, and acceptance of the result, rather than good technical guidelines.

In addition, most of the motor leads can easily be routed away from more sensitive wiring, like wires to temperature sensors, etc., thereby reducing unwanted coupling to an acceptable extent.

By contrast, I have noticed reports of hot end temperature sensor readings being corrupted by PWM controlled hot end heater power feed, as the two sets of wires are often side-by-side over their entire length of perhaps 50cm, and the heater current may be around 3A.

-------------

Perhaps my thinking is totally screwed up by something obvious, so please reply if you have some evidence that suggests it is wrong, as it might be!

--------------

Of course, there will need to be data/control lines between a 'master' computer device and the stepper driver chips. Some thought and care is needed here, but this is much easier than the power flows discussed above. Maybe a subject for a separate missive?

-------------

-------------

A weird observation, largely unrelated to above:

DRV8825 data sheet says it can handle up to 45V, but there are other phrases in the data sheet like 

image

which appears at least twice, but I didn't find an obvious way of figuring out what the max drive current was at 40V, and the chip at a 'more realistic' operating temperature of say 50C, given that it is a small physical device, trying to lose a lot of heat through the small PCB it is soldered to, and perhaps a tiny heatsink and a fan.  (presuming you were not limiting its usage to outside in the middle of a snow-bound winter).

I have a feeling the only clues, if there any, might be buried in the dissipation discussions. I have only glanced, and shuddered at the thought of ploughing through them, just to find it doesn't have as much 'muscle' as you were hoping for! Maybe you have seen an answer or have a better idea?

-------------

Sorry, this is not meant to be, and isn't, a full check of your posting, but just a first reaction, whilst I remember it. I might have another look, in the coming days.

Best wishes, Dave



   
ReplyQuote
Inq
 Inq
(@inq)
Rocket Scientist or Space Cadet
Joined: 4 years ago
Posts: 2051
Topic starter  

Posted by: @davee

I get the impression that your research suggested you 'minimise' (A) length of wire from source (battery) to stepper motor driver chips, and you maximise (B) length from stepper motor driver chips to motors. Intuitively, (with NO practical experience of this particular case), this feels completely the wrong way round!

My 'thinking' is that ideally (A) will carry an "almost" constant current flow as the power input to the stepper driver chips should have sufficient capacitance attached (and possibly other filtering).

The stepper motors come with 1m length, 4 wire, like you mention, for easy use on a 3D printer where the drivers are directly on a motherboard next to the MPU.  However, having 40V, 1.6A, PWM over that meter sounded, even to me, like a bad idea and is why I posed the question to Gemini several days ago.  It lead off with, "I know it sounds counter intuitive, but..." and followed with a flowery speech and a whole lot of "sunshine" 😉.  Most of it, I either didn't quite grasp or totally ignored since it told me what I wanted to hear. 🙄 

The next couple of hours I spent following Dorothy down the rabbit hole trying to get 40V down to a clean 3.3V on the cheap.

But, I've had mixed success with AI.  Lot's of sunshine, but I know just enough to question some answers and often it'll come back, "You are right.  I missed that..." and the main reason I post hear hoping you or others with experience will confirm or find the flaws.  But, you know... I don't mind letting the smoke out.  I buy in bulk. 🤩 

So, just now, I re-posed the question to Gemini and now also to ChatGPT since it did a better job getting me through a software issue that Gemini totally wasted my time.  This is what I lead with:

driving two stepper motors with DRV8825 using ESP32-S3

and followed up with:

The stepper motors are 1 meter away from the 37V battery. The MPU will be near the batteries. The question is: do I put the DRV8825 next to the MPU and use the 4 wire bundle that comes with the stepper over the meter distance OR put the DRV8825 next to the stepper and run the 37 VDC, 1.6A power, 3.3VDC, GND, STEP and DIR logic lines all relatively close together over the 1 meter length? I am concerned about RF and having sensitive I2C and SPI sensors.

and low and behold, they gave me opposite answers:  Gemini - Driver at MPU, ChatGPT - Driver at Stepper.  I wouldn't ask anyone to read these answers, but there here for completeness.   

Gemini:

For optimal performance and minimal electromagnetic interference (EMI), you should place the DRV8825 drivers next to the MPU (battery side) and run the 4-wire stepper motor cables over the 1-meter distance.
Why Placing Drivers Near the MPU is Best
  • Protects Logic Signals: Running 3.3V high-frequency STEP and DIR lines over a 1-meter distance turns those wires into antennas. They will pick up stray electrical noise, causing missed steps or erratic motor behavior. Keeping them short (a few centimeters) ensures clean logic transitions.
  • Simplifies Power Delivery: Stepper drivers require a low-impedance connection to their bulk decoupling capacitors. Keeping the DRV8825 close to the 37V battery and MPU allows the capacitors to suppress voltage spikes effectively right at the source.
  • Reduces Wire Count: Running wires over a long distance introduces failure points. Extending the 4-wire motor bundle is much simpler than extending 6 separate lines (VMOT, GND, 3.3V, GND, STEP, DIR).
Mitigating Noise (RF) for Sensitive I2C and SPI Sensors
The 4-wire motor cables carry high-frequency, high-current chopped PWM signals, which are notorious for radiating radio frequency (RF) noise that can easily disrupt delicate I2C and SPI sensor lines. To keep your sensors safe over that 1-meter span, implement these wiring practices:
  • Use Shielded, Twisted-Pair Cables: For the 1-meter run to the motors, use a shielded cable. Pair the wires by motor coil: Coil A (A1 + A2) should be twisted together, and Coil B (B1 + B2) should be twisted together.
  • Ground the Shield Properly: Connect the outer braided shield of the motor cable to the main system ground only at the driver/battery end. Leave the shield completely disconnected at the motor end. This creates a Faraday cage that drains radiated noise to ground without creating a ground loop. [1]
  • Physical Separation: Route your sensor cables (I2C/SPI) as far away from the stepper motor cables as possible. If they must cross paths, make them cross at a 90-degree angle rather than running parallel to each other. [1]
  • Lower I2C Pull-Up Resistors: Standard internal microcontroller pull-up resistors (around 10kΩ) leave I2C lines highly vulnerable to noise over long distances. Add external 2.2kΩ or 4.7kΩ pull-up resistors to your I2C SDA and SCL lines to stiffen the bus against induced transients.

ChatGPT:

I would put the DRV8825s near the stepper motors, not next to the ESP32-S3/MPU.

That is the better EMC/RF architecture for what you're building.

Why

The important distinction is that the DRV8825 is generating high-current, rapidly switching PWM waveforms on the four motor wires. Those are much more electrically noisy than the STEP/DIR signals.

In other words:

Run the relatively clean signals 1 meter. Don't run the chopped motor current 1 meter if you can avoid it.

TI specifically recommends placing the DRV8825's local ceramic bypass capacitors very close to its VM pins and providing local bulk capacitance because the supply wiring has parasitic inductance and the driver produces rapidly changing current demands.

The 1-meter STEP/DIR run isn't particularly scary

STEP and DIR are digital signals, and at one meter they're quite manageable.  I'd run something like:

STEP ────────────────────────────────> DRV8825
DIR ────────────────────────────────> DRV8825
GND ────────────────────────────────> DRV8825 GND
 
But I would not run those wires as three random conductors bundled next to motor wires.

Instead, use twisted pairs if possible:  Or, even better, if you have room in the cable, use a cable arrangement where each signal has its own return.  For example:

STEP ───── twisted with ───── GND
DIR ───── twisted with ───── GND
 
You don't need to send 3.3 V over the cable if the DRV8825 logic is powered locally. The DRV8825's control interface is STEP/DIR, and its operating supply is 8.2–45 V.  (I know this isn't right because the RESET, SLEEP, and if micro-stepping is used M0, M1 and/or M2 must have 3.3V!  Inq)

I would NOT put 37 V and STEP/DIR in the same bundle casually

This is the part I'd pay attention to.  If you do:

37V ───────────────────────────────
GND ───────────────────────────────
STEP ───────────────────────────────
DIR ───────────────────────────────
 

over the same cable, it's not necessarily a problem, but the physical arrangement matters.

The battery supply itself isn't inherently noisy. The problem is the current pulses generated by the DRV8825. If the driver is at the motor end, those nasty current loops are physically confined to the motor/driver area.  That's exactly what you want when your ESP32-S3 is sitting beside an MPU, particularly if you're using a sensitive IMU.

Keep the IMU physically away from the driver.

That keeps the high di/dt switching currents away from the MPU.


One important concern: your 37 V battery

This actually concerns me more than the one-meter STEP/DIR cable.

The DRV8825 has an operating range of 8.2–45 V, with a 47 V absolute maximum listed by TI.

A nominal 37 V battery is therefore fairly close to the upper limit.

You don't want:

 
 
37 V nominal
motor switching/transients
45+ V at VMOT
dead DRV8825
 

TI explicitly discusses the effect of power-supply wiring inductance and motor current transients and calls for local bulk capacitance at the driver.

So I would put the following right at each DRV8825:

 
 
37V ────────+──────── VMOT
|
[bulk
capacitor]
|
GND ────────+──────── GND
 
and
 
0.1 µF ceramic
very close to
VMOT/GND
 

TI specifies 0.1-µF ceramic bypass capacitors very close to the VMA/VMB pins and says additional bulk capacitance is required, with the amount depending on the wiring inductance and application.

With a 37 V battery, I'd also want to look carefully at the actual maximum battery voltage and transient environment before committing to the DRV8825. If "37 V" means a 10S lithium battery, for example, the fully charged voltage is substantially higher than 37 V.


What I'd do for your particular system

I'd choose:

Battery → 1 m power cable → DRV8825 → short motor cable

and

ESP32-S3 → 1 m STEP/DIR/GND cable → DRV8825

rather than:

ESP32/DRV8825 → 1 m motor cable → motor.

And I'd use:

  • twisted STEP/GND pair
  • twisted DIR/GND pair
  • shielded cable if practical
  • shield connected to chassis/ground at one end if you're dealing with significant EMI
  • local bypass/bulk capacitors at each DRV8825
  • short motor wires from DRV8825 to motor
  • physically separate the motor/driver wiring from the MPU and its I²C/SPI traces
  • keep the MPU and its I²C/SPI traces away from the 37-V switching circuitry
  • use a solid ground strategy rather than letting motor current share the MPU ground path

If the I²C/SPI bus is also going down that 1-meter cable, that's a different situation—I would not simply run ordinary 3.3-V I²C/SPI for a meter alongside the stepper wiring. I'd handle that separately.

One more thing

You mentioned 1.6 A power. If you mean the stepper motor is rated at 1.6 A/phase, that's an important distinction from saying the 37-V supply is limited to 1.6 A. The DRV8825 regulates the motor winding current, so the battery current can be considerably different from the motor's phase current.

If you give me the exact stepper motor model, 37-V battery type (e.g. 10S Li-ion), and the DRV8825 module you're using, I can lay out the recommended wiring—including capacitor values, wire arrangement, grounding, STEP/DIR filtering, and how I'd protect the ESP32/MPU from the motor EMI.

 



   
ReplyQuote
Inq
 Inq
(@inq)
Rocket Scientist or Space Cadet
Joined: 4 years ago
Posts: 2051
Topic starter  

Don't know if the analogy caries over, but in dynamic, mechanical systems, harmonic vibration at the same frequency is very bad!

The DRV8825 use 30 kHz PWM to the steppers and the STEP logic line can and will likely see the same 30 kHz.



   
ReplyQuote
(@davee)
Member
Joined: 5 years ago
Posts: 2055
 

Hi Inq,

   This feels a bit like Sermon Wars ... an elderly eccentric versus two or more text predictors 🙄 🙄 ... I don't think I am going to win on word volume. 🤣 

Reading your comments reminded me of former British comedy duo, who made a series of shows annually for many years, and each show finished with Bring Me Sunshine ... YouTube has an example, that is as cringey as some of the AI replies 

 

Noting the Tacoma analogy, resonance can indeed be a problem with stepper motors, but at high step speeds, I would also think about ensuring that any PWM for current control is many times higher frequency than the step speed, as otherwise, the current control pulsing will be eaten in whatever way the logic of the chips decides to do. Sorry, I haven't needed to worry about that in the past, and hence, I would need to look some 'realistic' speed etc. data to work through it from scratch ... not in this missive.

-------

To your Gemini vs ChatGPt quotes:

I don't think Gemini has 'considered' the wire length effects, but rather just followed cheap 3D printer 'norms'.

Phrases like 'high-frequency STEP and DIR lines' ignore :

  • The step motor line has a single pulse for 1 step. The motor drive is 'changed' by moving to the next step, but there is superimposed on a much faster pulsing PWM that determines the current flow
  • The step motor line is low current/power, so unlikely to cause significant radiation. Care is needed to ensure it acts like a 'faithful' transmission line, but this is down to good design, not trying to make the best of a difficult power transmission task, with multiple, often conflicting, issues.

The 4 versus 6 wires argument implies each wire is identical in its difficulty. Taken to the extreme absurd, consider the difference between the two live cores + neutral coming into your house versus a CAT-6 6 wire Ethernet cable!

Some of the secondary recommendations nearer the end of the Gemini script are more reasonable, but again too generic. eg Addition of pull up resistors needs considering, but physical placement and wiring topology on the network is also important for transmission lines of 'significant' length. 

ChatGPT seems more on the ball generally.

I think it "might" have a point regarding the 3.3V issue, as the DRV8255 includes a 3.3 voltage regulator, BUT its output is only 1mA. So either you or ChatGPT's view COULD be correct, depending on the current demand at the DRV8255 end. I haven't checked it, but first 'hypothesis' is that if the only load is a pair of 6.6k Ohm or higher pull up resistors at the DRV8255, then maybe the DRV8255 could source the current, but if the resistors are lower than 6.6kOhms, then an 'external' power source would be needed. I am not clear how much current at 3.3V the DRV8255 consumes internally, so this also needs to be taken into consideration.

---------------

In some cases, lower value resistors could be fitted at the microcontroller end, and no resistors at the DRV8255 end, will be good enough. Note that Philips original application note, when they introduced I2C to the world, accepted that 'classic' transmission theory ideals were unrealistic for I2C, and that the designer should use the 'suck it and see' approach for each design, using a scope to check that the waveforms were good enough.

If you do want a 'remote' 3.3v supply, I would consider using 5V along the wire and an extra remote AM1117 for  private 3.3v supply, near to the load that uses it ... not essential, but the AM1117 plus its capacitors should help to fllter any incoming noise

So this is an open question for now.

----------

Much of the rest of ChatGPT's effort looks sensible, although I would need to put in a lot more effort, probably including some kind of mock up, to check it properly.

Its point of current being different at different points is certainly valid.  In rough terms, the POWER into the motor should about the same as the POWER into the DRV8255.

Oversimplifying, if the average motor current is 1A, then the power input to the motor might be 2W. With a coil resistance of say 2 Ohms, this 'implies' the 'active' motor voltage is 2V.

Whilst the incoming voltage from the battery is (say) 40V.

The difference is a combination of the inductance of the coil,  opposing the incoming current, when the voltage is just applied, and the back emf when the motor is moving, and acting as a generator, as well as a motor. Of course, both of these are dynamic effects, and only occur when the voltage is being pulsed by a PWM driver, and the motor is moving. Nevertheless, even though the motor coil current may be 1A, the battery current may be nearer 1 / (40/2) = 1/20 = 0.05A. 

In reality, power losses due to resistance of coils, driver chip FETs and so on, will mean the actual current is higher than 0.05A, but it is unlikely to approach 1A. This is similar to a buck regulator, in which the output current can be considerably higher than the input current, if the output voltage is also considerably lower than the input voltage.

Of course, the stepper motors in consideration normally have two coils, so total current may be up to twice the maximum current of each phase. I seem to recall discussing this in more detail some years ago, with reference to how microstepping is implemented.

I assume a 10 cell Li-ion battery voltage will reach at least 42v whilst charging, maybe higher? This higher voltage needs to be accommodated, for magic smoke risk to be reduced.

-------------

My principal concerns that the DRV8255 data sheet talks about 24V as a kind of 'normal' remain. My guess is that the higher voltage refers to occasions when current, and hence power dissipation is low. I am reminded that vehicles with 24V lead acid batteries usually have semiconductor parts with operating voltage limits considerably above 24V, apparently to provide a little headroom for transients, such as when a starter motor is operated.

This is pure speculation on my part, but given the DRV8255 is dated 2010-2014 for the main document, could this explain the lack of operating data for different voltages? I.e. TI only expected it to ever be used in 24V battery environment.

If so, assuming you wish to drive 'substantial' motors, at 40+V supply, rather than 24-ishV, I suspect you will have issues with these chips.

I haven't looked in detail, but I think the TMC range, now from Analog Devices, includes voltages considerably beyond the mid 20V range, but they require external FETs to do the power and heat dissipation handling, plus external FETs can have much lower RDS on, and hence dissipate less heat.

Of course, these devices are more expensive, etc., but maybe more appropriate. Most of the rest of the discussion above will still apply. I think some are available on 'compatible' PCBs.

----------------------------------------------------------------------------------------------------------------------

Unlike text predictors, I get tired and expected to do other chores, so I'll leave this sermon here. I hope it's helpful.

Best wishes, Dave 



   
ReplyQuote
byron
(@byron)
No Title
Joined: 7 years ago
Posts: 1276
 

Posted by: @davee

Reading your comments reminded me of former British comedy duo

😀 Now I will always think of @inq as a man with short fat hairy legs 😯 



   
Inq reacted
ReplyQuote
(@davee)
Member
Joined: 5 years ago
Posts: 2055
 

@byron

  Because @Inq is the Wise one perhaps?

😀



   
ReplyQuote
byron
(@byron)
No Title
Joined: 7 years ago
Posts: 1276
 

Posted by: @davee

Because @Inq is the Wise one perhaps?

Boom Boom as Basil Brush would say 😀 



   
ReplyQuote
Inq
 Inq
(@inq)
Rocket Scientist or Space Cadet
Joined: 4 years ago
Posts: 2051
Topic starter  

🤣 I'm going to have to dig out some time watch these... and maybe more.

I did finish the tile work and my wife will do the grout and painting, then I'll do the trim and we're back in!

Also, as my wife say, I start "Big Boy School" tomorrow.  Looking forward to it!



   
ReplyQuote
Inq
 Inq
(@inq)
Rocket Scientist or Space Cadet
Joined: 4 years ago
Posts: 2051
Topic starter  

In my previous projects I tended to jump from subject to subject in a free flowing rambling that probably made me sound like I have A.D.D!  This time around, I'll take a clue from the way @robotbuilder creates new topics when a tangent strikes him.  I'll take a more concerted effort to keep this one strictly about the physical, electronic, motor driven robot and spawn off when I feel a tangent coming on.

Starting with the development of an Artificial Neural Network and the purely software related topic at:  https://forum.dronebotworkshop.com/neural-networks/building-a-neural-network-from-the-ground-up

 

Inq

P.S. - But I do have A.D.D. in spades!



   
ReplyQuote
robotBuilder
(@robotbuilder)
Member
Joined: 7 years ago
Posts: 2571
 

@inq 

In my previous projects I tended to jump from subject to subject in a free flowing rambling that probably made me sound like I have A.D.D!

It is now called Attention Deficit Hyperactivity Disorder.

Its advantages often include hyperfocus, boundless creativity, and high resilience.



   
ReplyQuote
Page 3 / 4