CNCzone.com-The Largest Machinist Community on the net!



Home Page Mark Forums Read Today's Posts My Replies Classifieds Reviews Photo Gallery Web Links Share Files Advertise With Us Ad List
Go Back   CNCzone.com-The Largest Machinist Community on the net! > OpenSource CNC Design Center > Open Source Controller Boards


Open Source Controller Boards Discussion for Open Source CNC type Controller Boards and other related items. (for personal use only)


This forum is sponsored by:

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Ban this user!
Old 10-23-2007, 09:14 AM
 
Join Date: Oct 2006
Location: Australia
Posts: 451
Eclipze is on a distinguished road
Trinamic Driver IC's - thoughts on using them with external FETs

I've been looking at the Trinamic drivers. They are obviously not the simple step/direction type, but even so, I'm surprised they haven't been talked about more. They are used via an SPI link. However it is quite feasible to have a small micro provide the normal step/dir interface, but also allow for a lot of configurability through other means.

The TMC236 and TMC246 are both 1.5A driver, where the 246 has StallGuard (motor stall detection). The TMC239 and TMC249 are both designed to drive external MOSFETs (249 with StallGuard). So higher currents/voltages possible.

They have 4-bit DAC which allow 1/16 step. Mixed decay can be switched on and off, and give a small micro, could be programmed to enable this as required on the fly. It uses a fixed frequency chopper to set current levels, which can have an external frequency fed to it. It uses digital blanking, with 4 selectable values. These could be jumper selected, but perhaps the micro could also control this setting to obtain shorter chopper pulses (lower current), but extend the blanking for higher current steps.

There is also some warning (over current, over temperature), but also a 3-bit load indicator based on motor back EMF. Would be nice to have 3 LEDs show the load on the stepper (helpful for setting feedrate). Though it looks like this only works in full step mode. Sensorless stall detection using this is possible, given you follow a string of steps to make it reliable.

The interesting part is that the DACs can use an external reference. So you can control the maximum current to the stepper. This will definitely help with matching the maximum current to the motor used, but... if the little micro controls this reference (via DAC), you could have the current step down when idle (like 50%).

Of course the maximum current and high voltage operating is a key point for CNC machines. The 236/246 are targeted at directly driving small steppers, while the 239,249 are lower current and targeted to drive external FETs. But the gate drive on these are pretty weak. I was think of using the higher current 236/246 as a beefy pre-driver to external FETs.

Apart from the complexity in boosting to higher power output stage and potentially higher cost (TMC part + small micro to support step/dir and configurability control) these seem to have some good flexibility/features on paper.

I have looked over their controller chips, like the TMC401, but you lose all the configurable flexibility that makes the driver so interesting to start with.

Has anyone ever used these chips or have any thoughts?



Links
http://www.trinamic.com

TMC246 Datasheet
http://www.trinamic.com/tmc/media/Do..._datasheet.pdf

TMC249 Datasheet
http://www.trinamic.com/tmc/media/Do..._datasheet.pdf

239/249 - App note for boosting to higher voltage FET
The circuit uses IR2101S as pre-drivers (HI & LO driver for each half bridge) to Si4450DY FETs, though they are a little undersized in an SO8 at 24mohm RDSon. Lot of parts to support this.
http://www.trinamic.com/tmc/media/Do...schematics.pdf
Reply With Quote

  #2   Ban this user!
Old 10-25-2007, 02:39 PM
 
Join Date: Dec 2005
Location: Usa
Posts: 93
Horsedorf is on a distinguished road
Buy me a Beer?

an interesting device. Not sure teh max rate given that it's using i2c to control the gates.

I don't THINK you can use it to drive an external FET and still get all those nice features you want, though.

Also, the load seems to noly be 'updated' every full step, so you can use it with microstepping, it looks like, but you only get a new load value every full step.

Huh. I like it. The 249 that is. Kinda spendy though at nearly $13 each from newark. i didn't find them at mouser.
Reply With Quote

  #3   Ban this user!
Old 11-05-2007, 04:04 PM
 
Join Date: Oct 2007
Location: USA
Posts: 9
JohnDH is on a distinguished road
Trinamic Drivers for external FETs

Hi,
I have used these driver ICs to build 100V 10A Drivers. The microprocessor needs to provide an oscillator clocklike output to keep the top FET turned hard on when the motor is not moving, and you need very careful PCB layout and an 8X Op Amp stage to get good current sampling. Trinamic provides a complete and detailed schematic for the FET drive stages. Watch the capacitor voltage ratings some are OK at 16V but others need 100V.

I use an Atmel ATmega168 to do the step and direction to SPI conversion

Regards

JohnDH

Originally Posted by Eclipze View Post
I've been looking at the Trinamic drivers. They are obviously not the simple step/direction type, but even so, I'm surprised they haven't been talked about more. They are used via an SPI link. However it is quite feasible to have a small micro provide the normal step/dir interface, but also allow for a lot of configurability through other means.

The TMC236 and TMC246 are both 1.5A driver, where the 246 has StallGuard (motor stall detection). The TMC239 and TMC249 are both designed to drive external MOSFETs (249 with StallGuard). So higher currents/voltages possible.

They have 4-bit DAC which allow 1/16 step. Mixed decay can be switched on and off, and give a small micro, could be programmed to enable this as required on the fly. It uses a fixed frequency chopper to set current levels, which can have an external frequency fed to it. It uses digital blanking, with 4 selectable values. These could be jumper selected, but perhaps the micro could also control this setting to obtain shorter chopper pulses (lower current), but extend the blanking for higher current steps.

There is also some warning (over current, over temperature), but also a 3-bit load indicator based on motor back EMF. Would be nice to have 3 LEDs show the load on the stepper (helpful for setting feedrate). Though it looks like this only works in full step mode. Sensorless stall detection using this is possible, given you follow a string of steps to make it reliable.

The interesting part is that the DACs can use an external reference. So you can control the maximum current to the stepper. This will definitely help with matching the maximum current to the motor used, but... if the little micro controls this reference (via DAC), you could have the current step down when idle (like 50%).

Of course the maximum current and high voltage operating is a key point for CNC machines. The 236/246 are targeted at directly driving small steppers, while the 239,249 are lower current and targeted to drive external FETs. But the gate drive on these are pretty weak. I was think of using the higher current 236/246 as a beefy pre-driver to external FETs.

Apart from the complexity in boosting to higher power output stage and potentially higher cost (TMC part + small micro to support step/dir and configurability control) these seem to have some good flexibility/features on paper.

I have looked over their controller chips, like the TMC401, but you lose all the configurable flexibility that makes the driver so interesting to start with.

Has anyone ever used these chips or have any thoughts?



Links
http://www.trinamic.com

TMC246 Datasheet
http://www.trinamic.com/tmc/media/Do..._datasheet.pdf

TMC249 Datasheet
http://www.trinamic.com/tmc/media/Do..._datasheet.pdf

239/249 - App note for boosting to higher voltage FET
The circuit uses IR2101S as pre-drivers (HI & LO driver for each half bridge) to Si4450DY FETs, though they are a little undersized in an SO8 at 24mohm RDSon. Lot of parts to support this.
http://www.trinamic.com/tmc/media/Do...schematics.pdf
Reply With Quote

  #4   Ban this user!
Old 11-05-2007, 11:42 PM
 
Join Date: Oct 2006
Location: Australia
Posts: 451
Eclipze is on a distinguished road

Speaks volumes when someone has actually used them.

PCB layout isn't a problem, I do a lot of surface mount board designs. I'II have to look through their apps notes.

Did you find the microstepping was accurate... not skipping or doing anything weird?
Reply With Quote

  #5   Ban this user!
Old 11-06-2007, 09:32 AM
 
Join Date: Oct 2007
Location: USA
Posts: 9
JohnDH is on a distinguished road
Trinamic FET Drivers

Microstep accuracy mostly depends on the motor. There is a common test to determine if a motor is good for microstepping. drive the motor shaft and look at the A winding on the X axis and the B winding on the Y axis of a scope (no timebase) If you see a circle on the screen, good microsteping accuracy. If it looks more like a square with rounded edges, not so good.

A benefit of using microstepping is that it reduces the risk of loosing steps

The curent sense part of the Trinamic circuit is good for 3 or 4 Amps but unless you want to use very high wattage sense resistors at 10 Amps or more you need to go to a very low value sense resistor (50 milliohm) and add an op amp (8X) in the feedback path; however this makes the layout of this part of the circuit very critical.

Use big safety margins on the FET ratings. For 10 Amps I use 30A FETs. For 80V I use 100V FETs

You also need big caps on the FET power line. 1,000UF per Amp is good, and a cluster of low ESR caps in parallel is better than one big cap
Reply With Quote

Sponsored Links
  #6  
Old 11-06-2007, 11:20 AM
Gold Member
 
Join Date: Mar 2003
Location: United States
Posts: 2,717
Mariss Freimanis is on a distinguished road

Small point but a 4-bit DAC doesn't get you 16 microstep resolution. At best it is 4 to 5 microsteps.

Microstep resolution = 90 / (90 - arcsin (2^(n-1) / 2^n))

For n = 4, (DAC resolution in bits) gives a 4.42 microstep accuracy. You need an 8-bit DAC to get 16 microstep accuracy. Please check my equation; I conjured it up in 5 minutes.:-)

Mariss
Reply With Quote

  #7   Ban this user!
Old 11-06-2007, 11:51 AM
 
Join Date: Dec 2005
Location: Usa
Posts: 93
Horsedorf is on a distinguished road
Buy me a Beer?

Originally Posted by Mariss Freimanis View Post
Small point but a 4-bit DAC doesn't get you 16 microstep resolution. At best it is 4 to 5 microsteps.

Microstep resolution = 90 / (90 - arcsin (2^(n-1) / 2^n))

For n = 4, (DAC resolution in bits) gives a 4.42 microstep accuracy. You need an 8-bit DAC to get 16 microstep accuracy. Please check my equation; I conjured it up in 5 minutes.:-)

Mariss
Uhhhh... (2^(n-1)/2^n) is allways .5, Though I think the gist of what you are trying to show is that the accuracy of the comoparator has to be higher at the extreme ends where the current differentiation is lower. yes?

Horsedorf
Reply With Quote

  #8  
Old 11-06-2007, 01:19 PM
Gold Member
 
Join Date: Mar 2003
Location: United States
Posts: 2,717
Mariss Freimanis is on a distinguished road

Bracket trip-up. Let's try this:

Resolution = 90 / (90 - arcsin ((2^n) - 1) / 2^n))

Or:

Resolution = 90 / (90 - arcsin (1 - 1 / 2^n))

My point is microstepping requires sine / cosine motor currents for evenly spaced microsteps. If these currents are generated from a sin/cos lookup table and a pair of DACs, the resolution of the DAC will set minimum angular resolution of the resulting microsteps.

Mariss
Reply With Quote

  #9   Ban this user!
Old 11-06-2007, 01:42 PM
 
Join Date: Dec 2005
Location: Usa
Posts: 93
Horsedorf is on a distinguished road
Buy me a Beer?

Originally Posted by Mariss Freimanis View Post
Bracket trip-up. Let's try this:

Resolution = 90 / (90 - arcsin ((2^n) - 1) / 2^n))

Or:

Resolution = 90 / (90 - arcsin (1 - 1 / 2^n))

My point is microstepping requires sine / cosine motor currents for evenly spaced microsteps. If these currents are generated from a sin/cos lookup table and a pair of DACs, the resolution of the DAC will set minimum angular resolution of the resulting microsteps.

Mariss
Yah, I THOUGHT you were trying to say that, but i was being super lazy and just letting you redo the math. And yup, They are using a dac with a linear output to feed the comparators. Apparently for current limitting, however, there is a second measuring/control stage after that. Without having looked at it that closely yet, I'm wondering if perhaps they have something that either has greater resolution in that section, or somehow 'unlinearifies' the comparison between current current and what they wish the current to be. Still though, an interesting device!

Horsedorf

Oop. never mind. Looks like it's just their load measuring thing they do to see how loaded up the motor currently is. Which bring us to the other point.. if 4 bits isn't enough, they are either mislabling the system, or the microsteps are not even, or they are doing "something else" to get around the issue.

Last edited by Horsedorf; 11-06-2007 at 01:47 PM. Reason: Found new info
Reply With Quote

  #10  
Old 11-06-2007, 02:22 PM
Gold Member
 
Join Date: Mar 2003
Location: United States
Posts: 2,717
Mariss Freimanis is on a distinguished road

A well-designed step motor has 2 attributes:

1) Motor torque is the vector sum of the phase currents (T = SQRT (Ia^2 + Ib^2)). Only sine and cosine satisfies the requirement that torque be independent of angular location.

2) The motor angular location is the vector angle of the phase currents (Theta = arcsin Ia / (SQRT (Ia^2 + Ib^2)).

"Mislabeling" is a little harsh.:-) We'll agree a linear 4-bit DAC uses every every code combination only when a ramp is generated and manifestly a ramp is not a sine function.

There is a common technique using multiple silicon diodes to clamp a ramp at carefully chosen levels to synthesize a sine function from a triangle wave. This technique was used in tri-wave (square, triangle and sine) function generator ICs (Intersil 8038?). Perhaps this is what is being used to "delinearize" the DAC output.

Alternately, it may be jumping to conclusions to assume the DAC is a linear one (R / 2R ladder network). It is plausible the 4 bits are decoded by a "1 of 16" demultiplexer with the outputs going to sine and cosine weighed resistors to generate the DAC outputs.

I haven't looked at the drive and/or ICs so my comments are conjecture only.

Mariss
Reply With Quote

Sponsored Links
  #11   Ban this user!
Old 11-07-2007, 09:13 AM
 
Join Date: Oct 2007
Location: USA
Posts: 9
JohnDH is on a distinguished road

The basic parts of a microstep system are an up/down counter, a sine look-up-table, and a pair of DACs. Stepping causes the counter to increment, the parallel output of the counter is used to index the look-up-table and the output from the table drives the DACs. The number of DAC bits only determine the accuracy of the sine and cosine values. The counter and look-up-table bits determine the step resolution. Read this Allegro data sheet http://www.allegromicro.com/en/Produ.../3980/3980.pdf for a more detailed description
Reply With Quote

  #12   Ban this user!
Old 11-07-2007, 09:45 AM
 
Join Date: Dec 2005
Location: Usa
Posts: 93
Horsedorf is on a distinguished road
Buy me a Beer?

Originally Posted by Mariss Freimanis View Post
A well-designed step motor has 2 attributes:

[excellent description of microstepping angle snipped]

Mariss
Thank you Mariss, that actually helps a lot in understanding how these work.. The one thing I would then point out is that in the part description is that the dac output is a linear function of 6.25% of the current per step. So I'm thinking either this device won't work well, or the technical writer made a mistake in the description. I've seen other folks on here using this device with good results, so I'm assuming the writeup is incorrect. And yes, "mislabeling" IS harsh, but then I've seen a lot of parts produced over the years with horrifying errors in them! That never stops a determined marketting team that I've seen so far.

horsedorf
Reply With Quote

Reply




Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Trinamic Anodizer Open Source Controller Boards 3 11-17-2010 12:58 PM
1/4 NPT External thread program JerryH G-Code Programing 5 08-28-2008 07:37 AM
External Print Server? scratch_6057 Computers and Networking 0 05-25-2007 08:57 AM
External E-stop Requested ??? Wtf! diarmaid Mach Mill 54 12-10-2006 02:51 PM
Source for Allegro 5804B IC's - Qty 10??? FrankG Open Source Controller Boards 4 01-30-2005 05:11 AM




All times are GMT -5. The time now is 12:53 AM.





Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
Content Relevant URLs by vBSEO
Template-Modifications by TMS

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361