New Products Flash Sale
Thread Tools
Old Apr 25, 2013, 02:16 AM
hd27 is offline
Find More Posts by hd27
Baris ALP
Turkey, Gaziantep Province, Gaziantep
Joined Dec 2005
28 Posts
Quote:
Originally Posted by thanhTran View Post
bss123 FET doesn't drive the motors. The IRF7343 FETs drive the motors. they can drive up to 3.4A
No, be careful.
irf7343 datasheet says,
3.4A@vgs=10V
2.7A@vgs=4.5V
Stm32 drives 5v so it can drive 2.7A.
hd27 is offline Find More Posts by hd27
Sign up now
to remove ads between posts
Old Apr 25, 2013, 02:29 AM
nicodh is online now
Find More Posts by nicodh
Registered User
Joined Jan 2011
1,082 Posts
Quote:
Originally Posted by hd27 View Post
No, be careful.
irf7343 datasheet says,
3.4A@vgs=10V
2.7A@vgs=4.5V
Stm32 drives 5v so it can drive 2.7A.
And you are seriouly wrong.

In FET you have two stages, the power stage and the gate (whatever the name is).

The power stage is run with the voltage you want. Up to 55v in the case of IRF7343.

And i don't think that a stm32 will drives more than 100mA (and i think i'm exagerating)
nicodh is online now Find More Posts by nicodh
Old Apr 25, 2013, 03:07 AM
hd27 is offline
Find More Posts by hd27
Baris ALP
Turkey, Gaziantep Province, Gaziantep
Joined Dec 2005
28 Posts
Quote:
Originally Posted by nicodh View Post
And you are seriouly wrong.

In FET you have two stages, the power stage and the gate (whatever the name is).

The power stage is run with the voltage you want. Up to 55v in the case of IRF7343.

And i don't think that a stm32 will drives more than 100mA (and i think i'm exagerating)
You didn't understand.
I'm talking about current.
Yes power voltage can be 55V (Vds).
Gate voltage (Vgs) max +-20V
If you give 10V to gate, you get 3.4A. (P channel)
If you give 4.5V to gate, you get 2.7A. (P channel)
Stm32 gives 5v to gate.
hd27 is offline Find More Posts by hd27
Old Apr 25, 2013, 03:20 AM
thanhTran is offline
Find More Posts by thanhTran
That tree again!!!!
thanhTran's Avatar
Germantown, MD, US
Joined Sep 2004
6,644 Posts
Got it, thanks HD27
thanhTran is offline Find More Posts by thanhTran
Old Apr 25, 2013, 11:16 AM
timecop is offline
Find More Posts by timecop
Suspended Account
Joined Dec 2010
11,763 Posts
stm32 runs at 3V
timecop is offline Find More Posts by timecop
Old Apr 25, 2013, 11:45 AM
Tom Frisch is online now
Find More Posts by Tom Frisch
Registered User
Portland, OR, USA
Joined Mar 2010
269 Posts
So at 3v we are looking at under 2A? That doesn't sound so great- how many amps are needed to hold a larger camera?

And is it really 4 degrees of accuracy from the 90 sine LUT? Is that fine enough resolution?
Tom Frisch is online now Find More Posts by Tom Frisch
Old Apr 25, 2013, 11:53 AM
timecop is offline
Find More Posts by timecop
Suspended Account
Joined Dec 2010
11,763 Posts
I dunno

sine drive on esc32 (0 min 19 sec)


this was like 6 lines of actual code and i just used sinf().
I see hes using lookup table but thats for attitude not for motor control.
no idea why, the ADC1Ch1_vid stuff is weird because he has this:
Code:
		ADC1Ch1_vid=  ((ADC1Ch1_vid*99.00)+(readADC1(1)/4000.00))/100.00;	//Averaging ADC values
		ADC1Ch1_vid=0.00;
so its basically a no-op

cause
Code:
		sinus   = sinusas[(int)(ADC1Ch1_vid*57.3)];      //Calculating sinus		
    cosinus = sinusas[90-(int)(ADC1Ch1_vid*57.3)];   //Calculating cosinus
will always just be zero. ADC1Ch1_vid = 0, sinuses[0] = 0, cosinus will be sinuses[90] which is i think 1.0
timecop is offline Find More Posts by timecop
Old Apr 25, 2013, 01:57 PM
Tom Frisch is online now
Find More Posts by Tom Frisch
Registered User
Portland, OR, USA
Joined Mar 2010
269 Posts
What is ADC1ch1_vid storing? Is it a value from the IMU? or from the RC PWM input?
Tom Frisch is online now Find More Posts by Tom Frisch
Old Apr 25, 2013, 03:13 PM
evvaldis is offline
Find More Posts by evvaldis
Registered User
evvaldis's Avatar
Lithuania
Joined Jan 2007
182 Posts
Quote:
Originally Posted by Tom Frisch View Post
What is ADC1ch1_vid storing? Is it a value from the IMU? or from the RC PWM input?
Sorry for big delays, very busy week. I am on trip to Scotland now.
Adcch1 was for testing pitch control, i used potentiometer readings for testing pitch tilt control.
Sinus lut used for stabilisation recalculation while pitch axis is tilted.
Auirf now is changed to other more powerfull mosfets(same so8 package).Will post name as soon as posible.
And yes,at this time i am doing this project all by myself, therefore is hard to make everything nice and clear.. But if there is interest I would be happy to answer questions.
evvaldis is offline Find More Posts by evvaldis
Old Apr 25, 2013, 03:30 PM
Tom Frisch is online now
Find More Posts by Tom Frisch
Registered User
Portland, OR, USA
Joined Mar 2010
269 Posts
Thanks for your answers. I was hoping to build something very similar to what you are doing, so maybe I can help out.

How are you combining the gyro and accelerometer data?

Are you planning on adding support for a compass/mag sensor?
Tom Frisch is online now Find More Posts by Tom Frisch
Old Apr 28, 2013, 12:02 PM
evvaldis is offline
Find More Posts by evvaldis
Registered User
evvaldis's Avatar
Lithuania
Joined Jan 2007
182 Posts
Quote:
Originally Posted by Tom Frisch View Post
Thanks for your answers. I was hoping to build something very similar to what you are doing, so maybe I can help out.

How are you combining the gyro and accelerometer data?

Are you planning on adding support for a compass/mag sensor?
I am back

gyro/acc is combined with one simple line, something like:
roll_angle =(roll_angle + ROLL*dt) + 0.0002*(acc_roll_angle-roll_angle);
where:
roll_angle - roll horizon in radians.
ROLL - roll gyro data
dt - program loop time (0,002s)
0.0002 - accelerometer "weight" constant
acc_roll_angle - accelerometer horizon in radians.


compass/mag would be nice, but it is not most important thing to do at this time
correctly calibrated gyro drifts few degrees/min or even less, so it is fine even with gyro.
evvaldis is offline Find More Posts by evvaldis
Old Apr 28, 2013, 12:37 PM
evvaldis is offline
Find More Posts by evvaldis
Registered User
evvaldis's Avatar
Lithuania
Joined Jan 2007
182 Posts
Updated first post: Added 3axis altium files.
I can post gerbers for iteadstudio if anyone's interested

And if someone has possibility to make pcb's faster than iteadstudio, send me one copy please;D
evvaldis is offline Find More Posts by evvaldis
Old Apr 28, 2013, 04:21 PM
evvaldis is offline
Find More Posts by evvaldis
Registered User
evvaldis's Avatar
Lithuania
Joined Jan 2007
182 Posts
Testing new features
EvvGC 3 axis brushless gimbal controller Yaw axis control (0 min 59 sec)

As you can see I added simple potentiometer under yaw axis and connected it to motor shaft.
evvaldis is offline Find More Posts by evvaldis
Last edited by evvaldis; Apr 28, 2013 at 04:54 PM.
Old Apr 28, 2013, 04:48 PM
SVentas is offline
Find More Posts by SVentas
Registered User
Lithuania, Vilnius Region, Vilnius
Joined Apr 2012
81 Posts
Hi evvaldis,
Congratulations on your OpenSource/Hardware project.
I'm just curious, why you use rectangle method as gyroscope integration method on such a powerful machine?
Code:
roll_angle =(roll_angle + ROLL*dt) + 0.0002*(acc_roll_angle-roll_angle);
I think that trapezoidal rule would be slightly better approach.
Code:
roll_angle =(roll_angle + (ROLL+ROLL_PREV)/2*dt) + 0.0002*(acc_roll_angle-roll_angle);
ROLL_PREV = ROLL;
Or you can double gyro sampling speed and use Simpson's rule. Something like that:
Code:
ROLL_TEMP = GetRoll(blabla); // Get the first sample;
ROLL = GetRoll(blabla);      // Get the second sample;
roll_angle =(roll_angle + (ROLL+ROLL_PREV+4*ROLL_TEMP)/6*dt) + 0.0002*(acc_roll_angle-roll_angle);
ROLL_PREV = ROLL;
SVentas is offline Find More Posts by SVentas
Old Apr 28, 2013, 04:51 PM
steadiworkz is offline
Find More Posts by steadiworkz
https://www.facebook.com/group
steadiworkz's Avatar
Joined Feb 2013
251 Posts
Looks very promising ! I wish I could code something like this but i'm only used to java scripting, seems like it would be possible to learn but id needs lots of help
steadiworkz is offline Find More Posts by steadiworkz


Thread Tools

Similar Threads
Category Thread Thread Starter Forum Replies Last Post
Discussion Open Source Brushless Gimbal edge0xc Multirotor Electronics 3072 Feb 28, 2015 04:00 AM
Idea Open Source Gopro Brushless Gimbal icais Multirotor Talk 16 Mar 28, 2014 12:07 PM
Discussion SkyLight SBG - GoPro 2 Version Released (+ GP3 Beta + 3 axis Alpha) !! ed_jza80 Multirotor Talk 494 Jan 03, 2014 10:09 AM
Sold open source brushless gimbal controller jy0933 Aircraft - Electric - Multirotor (FS/W) 57 Mar 26, 2013 07:02 PM
Sold [closed] open source brushless gimbal controller jy0933 Aircraft - Electric - Multirotor (FS/W) 16 Feb 26, 2013 09:19 AM