Thread Tools
This thread is privately moderated by timecop, who may elect to delete unwanted replies.
Jan 26, 2011, 04:23 AM
Suspended Account

I'm gonna make a cheap ESC that works good enough for ME

I started this thread in January and I thought people would care.
Apparently, they don't. Well, at this point neither do I. I just want stuff that works, and tearing up Chinese ESC to try out fail firmware written in assembly is not high on my list of things to do when I just want to fly garbage.

I tried to get some help from people but as most of you probably know, RC hobby is all talk and trolling and then there's one-two smart guys who won't share anything with you.

Originally I wanted to make something that would fit into MK-distroboard.
Well, that idea was a disaster because that basically limits me to using dumb parts in dumb form factor. Screw it. New plan:


I found a Chinese company who made separate power stage PCBs. What this means for me? I can make any (cheap) logic back for it and use (really cheap) Chinese power stage board for the rest. That means: single-sided, 2 layer design for my logic board. I'm way to lazy to assemble double-sided designs. This sandwich PCB sounds like a total win from manufacturing standpoint.

The current logic board (above) will solder on the back side of the power stage (below).

And you got some fets on the back side, Turnigy plush style:

Yes, I didn't bother using gate drivers, but neither does any other $10 chinaESC, and they work just fine. I'm also not measuring current.

But wait, you say, why don't you just buy Turnigy plush then and hack it up with some wire and bla bla bla, well that's what I don't wanna do.

Plus I don't agree with how PPM input is on turnigy, INT0 sucks as bad as Atmel itself.

Anyhow, I've got the power stages on the way, and I'm gonna panel a few of these logic boards on my next order of PCBs which will happen (whenever) and then I'll assemble and test some, and keep them all for myself.

These support PWM/I2C input and tarduino bootloader for reflash.
I've got a 8MHz or 16MHz crystal in these so PWM shouldn't be too noisy.

Oops. I didn't notice +/- on the china-power-stage was swapped until I took a good look at the assembled version. So I had to furiously re-layout swapping high side / low side / battery / gnd.
Which resulted in a bit cleaner looking layout anyway with LOTS OF FREE SPACE. old version saved here for MEGA LULZ

And this is all temporary fun until OP-ESC gets done.
Last edited by timecop; Aug 20, 2011 at 02:55 AM.
Sign up now
to remove ads between posts
Jan 26, 2011, 04:34 AM
Registered User
I don’t think that some Chinaman would take the venture of i2c ESC's, they are only good to use in multi-rotor copters and the like, they cant be connected to a regular Tx and be used in all the great and big world of all the flying, dirt, track and water vehicles that uses regular PPM ESC's.

But I think that its a good idea, having a tailor made software for the ESC's, but I would rater use better micros than the simple atmega8 used in the common ESC's, to have more control over the BLDC engines.
Jan 26, 2011, 05:12 AM
Registered User
hexa's Avatar
Sounds good. If you not noticed MK multirotors are becoming very popular in the rc world.
and would be more popular if the price was a bit cheaper.

this project seems like it will take a year or 2 to complete
Dont loose interest in this project. keep the ball turning you never knows
Jan 26, 2011, 05:18 AM
Suspended Account
Originally Posted by senso View Post
I don’t think that some Chinaman would take the venture of i2c ESC's, they are only good to use in multi-rotor copters and the like, they cant be connected to a regular Tx and be used in all the great and big world of all the flying, dirt, track and water vehicles that uses regular PPM ESC's.
But it's a market segment that can't continue being ignored, so... Either they deliver or someone else does (at a ripoff cost, as shown by current offerings).

Originally Posted by senso View Post
But I think that its a good idea, having a tailor made software for the ESC's, but I would rater use better micros than the simple atmega8 used in the common ESC's, to have more control over the BLDC engines.
Good, sounds like you just signed yourself up on board as a firmware developer. In all seriousness though, if atmega8 doesn't have enough sram/flash to make it do something awesome, by all means let's use something with better spec.
Jan 26, 2011, 05:34 AM
Registered User
Atmel as usual likes to give their costumers the no parts available a lot of time, and I already read out there that there is people using PIC24 and dsPIC for ESC's, as this will be targeted to multi rotors, I think that the last one is a great option, as it as a lot of high resolution timers(16 and 32 bits), and can generate a lot of pwm signals, so I think that one dsPIC running at 40MIPS will easily handle at least 3 brushless motors.
I dont mind being a software developer, and I hope in fact to create and aeronautics division in my university, a bit like the MIT one, but smaller lol.
I can program in C, C++ and assembly for AVR's and at least in C/C++ for PIC's and dsPIC's, assembly is just a matter of some time to study it.
Microchip has an huge section about BLDC control using PICS!

For example this PIC:

It has 18 pwm motor control outputs, so it can handle 3 BLDC by itself!
This is only a little example, because I must also remember about the Open BLDC motor controller being developed in an ARM-Cortex M3 micro-controller, and its like a side kick of the OpenPilot project, its intended to control only one BLDC but it might be able to control more, but its in an embrionary stage right now, but its a starter and instead of competing we can always joint forces.
Jan 27, 2011, 02:32 AM
Registered User
I have already made a DIY esc:

Maybe I can help

I use one dsPIC for every ESC a dsPIC33Fj16GS504 which is great for this application. I don't think a dsPIC can do multiple motors, because timing is very critical. And you also want some PID controller in it. But I am no expert in programming.
i made several hardware design, and the one above is now working for several hours. Also looked at multiple software algorithms but the one from ST seems to be the best because is requires no RC filters.
Last edited by TheRaver; Jan 27, 2011 at 02:43 AM.
Jan 27, 2011, 04:26 AM
Suspended Account
Yep, I saw your thread and these controllers.
How much current can each channel handle? Those FETs don't look too good on paper.

One thing though, I was thinking something single channel, not quad/hexa etc configuration as that would make things bigger, costlier, and if one channel burns, more difficult to repair.

Looking at your schematic, looks like you're following same thing as the towerpro/turnigy setup, where you have a fet driver (arrangement A in the pic below).
There's also Arrangement B (MK-2.0 version) and arrangement C (I'm told by people who know more than me that the last (C) setup is trash because it doesn't fully close one of the fets making it heat up and in general not very good implementation.

So, from these remaining 2 on top, which is the best way?
Driver? MK?
To me from cost perspective seems like driver way is good.
How much current needs to pass through pins 7/5 of IC2 in your schematic?
This is just the low current to turn on main fets, right?
Jan 27, 2011, 04:36 AM
Registered User
A gate driver is the best way, because they can supply high pulse currents which are needed for fets. The more current you put in the gate the better. The fet will heat up during the charge time of the gate capacitor. So making that time shorter by supplying more current it heats up less.

The fets can handle like 60A, their are much better fets only different packages, IRF has some nice fets. The main limitation with my design is the PCB. Because I only have 2 layers I was limited on the PCB trace width.

My fets never get warmer like 40 degrees as far as I have tested.
Jan 27, 2011, 04:47 AM
Registered User
It would be good if the target platform is a quad to allow for as much sensor feedback as possible, since quads are typically flown with micro controllers that can make use of this information, or in some cases are sending it back as telemetry.
RPM, total current, FET fault states, temperature, possible motor winding faults etc would all be good. Some of these would require extra sensors.
Also use a XTAL for precise RPM.
Jan 27, 2011, 05:19 AM
Registered User
If you want all this data, it is poperably needed to have High-speed I2C of SPI. Every byte on 400kHz takes about 20 to 25 us with highspeed 2 to 3 us
Jan 27, 2011, 05:51 AM
Suspended Account
MK2.0 sends back current + temperature (seems 3 bytes)
if (motor_read == motor_read_temperature) 
    BuffLen = 3; // read Current, MaxPwm & Temp
MK1.x sends back 1 byte (current).
Doesn't MK i2c run at 100khz? Besides, when you're controlling by I2C you don't really need sub-ms precision of regular PWM control, and... the motors/response is going to be slower than this anyway.

RPM reporting sounds like useful idea, can this be calculated without using hall effect sensors?
Jan 27, 2011, 06:40 AM
Registered User
if you want a 1kHz loop rate of your atitude control and send 3 bytes back on 400kHz times 4 controller is needs 240us of the total 1000us. Which is quiet a lot. A dsPIC can handle 1MHz i2c when designed properaly it would take only 96us for 3x4 bytes.

The RPM can be measured in sensorless control, it is only noisy in my controller. But the PID RPM controller works quiet well.
Jan 27, 2011, 08:39 AM
Registered User
But even an Atmega can do SPI at 8Mhz, SPI seems a little bit smarter in this application.

Nice ESC's, like the design, I will take a look into the schematic and the code if you dont mind.
Jan 27, 2011, 11:20 AM
Registered User
I believe that an dsPIC can do 20MHz spi. You only need good PCB design because timing is critical at 20MHz. Only downside of SPI is the extra I/O for chip select for every slave.
Jan 27, 2011, 11:48 AM
Registered User
The SPI acts like a shift register, maybe with some code tweaking, all the servos could be connected serially and only use a global chip enable.

Thread Tools

Similar Threads
Category Thread Thread Starter Forum Replies Last Post
Discussion Let me CNC your parts for nearly nothing. mattgatten Multirotor Drone Talk 632 Aug 29, 2013 07:17 PM
Discussion Let me CNC your CAMERA MOUNT for nearly nothing (Open source design) Zirt57 Multirotor Drone Talk 245 Feb 21, 2011 11:58 AM
Discussion New I2C to PWM converter for standard ESC obor Multirotor Drone Talk 158 Feb 11, 2011 12:52 PM
Complaint My thread in the for sale forums closed for no reason and now it won't let me open it BD Flyer Site Suggestions / Complaints 2 Jan 30, 2007 09:04 PM
open source brushless controller group design Ron van Sommeren Power Systems 1 Sep 18, 2003 05:54 AM