multiwii / multiwii-firmware Goto Github PK
View Code? Open in Web Editor NEWFirmware - GitHub mirror of the official SVN multiwii project
Home Page: https://github.com/multiwii/multiwii-firmware/wiki
Firmware - GitHub mirror of the official SVN multiwii project
Home Page: https://github.com/multiwii/multiwii-firmware/wiki
Hi.. I want to use this sensor. how can config? Thanks
Firstly, Thank you to everyone who contributed to the development and maintenance of this software. The generous nature of the open source community never ceases to impress!
Anyhow, I was experiencing some issues trying to compile the source ver 2.4 with support for UBLOX GPS protocol enabled in the config.h file, using arduino IDE., see following excerpt from the file:-
/* GPS protocol
NMEA - Standard NMEA protocol GGA, GSA and RMC sentences are needed
UBLOX - U-Blox binary protocol, use the ublox config file (u-blox-config.ublox.txt) from the source tree
MTK_BINARY16 and MTK_BINARY19 - MTK3329 chipset based GPS with DIYDrones binary firmware (v1.6 or v1.9)
With UBLOX and MTK_BINARY you don't have to use GPS_FILTERING in multiwii code !!! */
//#define NMEA
#define UBLOX
//#define MTK_BINARY16
//#define MTK_BINARY19
//#define INIT_MTK_GPS // initialize MTK GPS for using selected speed, 5Hz update rate and GGA & RMC sentence or binary settings
The compiler kept throwing back an error message :-
Arduino: 1.8.13 (Linux), TD: 1.53, Board: "Arduino Mega or Mega 2560, ATmega2560 (Mega 2560)"
GPS.cpp:1177:17: error: flexible array member in union
uint8_t bytes[];
^
exit status 1
flexible array member in union
at line 1177 in GPS.cpp, I changed the source from uint8_t bytes[]; to uint8_t bytes[32];
Apparently Arduino and CPP don't allow an array of undefined size in data structures.
This change seemed to allow the code to compile and my UBLOX NEO 6M GPS data was being transmitted to and reported by, MultiwiiConf.
I'm not sure that this is a good fix but it seems to work for me.
Hopefully someone more skilled than I can decipher this info and adjust the source code to make a robust solution to the problems I have experienced.
Thank you again for your excellent work in making this software available to the community. My hat goes off to you all!
Good morning.
I need to change motor pin in multiwii 2.4.
I use Arduino Nano and NRF24L01 so I need pin 11 for MOSI.
Please help me to change pin number 11 into pint number 5 or 6.
Thanks.
Hi everyone,
I have been trying to work with multiwii lib for my quad copter.
I have done all the setup and uploaded the desired sketches, everything is going clear into checking phase. What major problem i am facing right now is , i am not be able to ARM my quad copter by any of the given setting (YAW OR ROLL triggering).
Other settings i have properly implemented as given in the various tutorials.
Please help me overcome the trouble.
The Git repo has tags for "release-2.0" and "release-2.1", but no tag for the recent 2.2 release.
https://github.com/multiwii/multiwii-firmware/tags
The SVN repo on the other hand, has a "version-2.2"-tag, but does not seem to have have tags for 2.0 and 2.1...
The SVN repo indicates that the commit representing the 2.2 snapshot should be named "- fix comment close in config.h"
http://code.google.com/p/multiwii/source/detail?r=1363
http://code.google.com/p/multiwii/source/detail?r=1362
A commit with that message exists in the Git repo: 5af6d55
I have not verified that they are identical though...
Compiling the source with the following flags is no longer possible:
//#define NMEA
//#define UBLOX
//#define MTK_BINARY16
//#define MTK_BINARY19
#define INIT_MTK_GPS // initialize MTK GPS for using selected speed, 5Hz update rate and GGA & RMC sentence or binary settings
//#define VENUS8
It generates the following console output:
sketch/MultiWii.cpp.o: In function `setup':
sketch/MultiWii.cpp:717: undefined reference to `GPS_SerialInit()'
sketch/Protocol.cpp.o: In function `serialCom()':
sketch/Protocol.cpp:241: undefined reference to `GPS_newFrame(unsigned char)'
collect2: error: ld returned 1 exit status
exit status 1
Error compiling.
This did work well before in v2.3. As it is right now, with v2.4, it is not possible to configure the MTK gps modules.
Sorry for not being able to provide a fix at the moment.
There seems to be a bug in the pilotlamp.
Better is:
if (alarmArray[9] == 1) {PilotLampSequence(100,B000111,2);return;} //I2C Error ==>All Blink ** just comment on the pattern ***
if (alarmArray[6] == 4) {PilotLampSequence(100,B0101<<8|B00010001,4);return;} //vbat critical ==>Running leds * Original Beeperon has no meaning or function here It is a light code pattern to be used for failsafe or vbat critical or something
Added return to avoid overlapping led steering to the pattern since both these pattern are intended for serious fault
There doesn't seem to be an option for the Multiwii Pro, HexTronik board in the options. What do I configure too for this board? How do we add this board to the selection? Is there already a firmware option that supports this board?
Please advise.
Hello, I am trying to trigger a parachute with a naze32 Acro and for that I need to get the altitude and velocity values. So I used printf to watch their values:
printf("Alt = %d ",(int)accAlt);
printf("VitZ = %d\n",( int)accZ_tmp);
But the altitude value isn't right at all. It's changing pretty slowly and the values are huge while it's suppose to be in centimeters. The velocity have pretty much same problems.
The values get also completly crazy when I turn the card upside down.
Is it normal? If it's not how can I fix this?
Thank you in advance for your answers.
any chance to get support for the BMP 280 sensor?
On multiwii v2.5 board with 328p if I enable i2c gps and msp wp command set the magnetometer and barometer update erratically and show odd values. Everything works fine with i2c gps disabled.
A div by zero will occur in the _atan2 (https://github.com/multiwii/multiwii-firmware/blob/upstream_shared/IMU.cpp#L134)
Code with no div by zero would be this:
int16_t _atan2(int32_t y, int32_t x)
{
float z = y;
int16_t a;
uint8_t c;
c = abs(y) < abs(x);
if (c)
{
if(x) z = z / x;
else return 0;
}
else
{
if(y) z = x / z;
else return 0;
}
a = 2046.43 * (z / (3.5714 + z * z));
if (c)
{
if (x < 0)
{
if (y < 0) a -= 1800;
else a += 1800;
}
}
else
{
a = 900 - a;
if (y < 0) a -= 1800;
}
return a;
}
The next thing is the possibility of feeding InvSqrt with zero here: https://github.com/multiwii/multiwii-firmware/blob/upstream_shared/IMU.cpp#L270 resulting in a bogus value (no div zero this time..).
That could be avoided:
...
int32_t zerochk = sqGX_sqGZ + mul(EstG.V16.Y,EstG.V16.Y);
if(!zerochk) return;
invG = InvSqrt(zerochk);
...
Plz somehow fix that.
Ps: That InvSqrt has more precision (2.6 times):
float InvSqrt(float x)
{
uint32_t i = 0x5F1FFFF9 - (* (uint32_t_)&x >> 1);
float tmp = * (float_)&i;
return tmp * (1.68191409f - 0.703952253f * x * tmp * tmp);
}
see http://www.multiwii.com/forum/viewtopic.php?f=8&t=4246&start=50#p50981
Hello,
Setup - Used Arduino Nano, MPU6050 and BMP085 as sensors. Using the Multiwii Version 2.4. Configured the config.h file to use QuadX, enabled MPU6050 and BMP085 from independent sensors. Selected PPMSumReceiver on pin D2 using an ESP32. So basically, ESP32 receives input over Wi-fi as IP data packets and pipes it to pin D2 of the Arduino. 4 motors are on default pins (3, 9, 10 and 11).
Now, I arm the drone, it gets armed, the 4 motors spin at minthrottle of 1064. So far so good. But when I send Throttle 25%, and roll, pitch and yaw to be 0%, all motors except the motor at pin D11 doesn't change speed. This is causing an imbalance and the drone to flip over. But when given random commands such as throttle 50%, yaw 100%, roll 0% and pitch 50%, it starts to give thrust (it changes speed) on D11 motor. But motors on D3 and D9 goes to no thrust (neutral speed, speed of 1064). Again, if we give random values, weird stuff keeps happening.
Is there a solution to this? I already checked motor connections, calibrated ESC's and tried dynamic balancing. Please let me know if you figure out a problem.
Thanks.
Good day,
When testing the MultiWii program, I don't have data coming from the pin D4 (ROLL). Although everything else works fine, I can read the PITCH, YAW, THROTTLE, etc.
My setup is:
Tests I've made:
Do you guys have any ideas where that can come from?
Anyone is in touch with one of the programmers?
Thanks for your answers
Regards,
JorusTyron
I can't register on the multiwi forum and I can't get a reply via "Contact a Board Administrator".
When I try to register I just don't get a validation email.
I also already wrote an email to [email protected].
Hi deveopers id make a WishList for
I know multiwii has been dated but age well , and the sensors it was build for are difficult to find in good quality these days, thinking we need to add new fresh sensors into the support list
looking for contributors for those who wish to add new sensors . hit me up here on discussions //
ICM20948, ICM42605, BMP388, BMI270, BMI160, LSM9DSI
there were a few added in recent years but still lacking
https://github.com/synersignart/Multiwii-2020-update
Hello,
Setup - Used Arduino Nano, MPU6050 and BMP085 as sensors. Using the Multiwii Version 2.4. Configured the config.h file to use QuadX, enabled GY521 and BMP085 from independent sensors. Selected PPMSumReceiver on pin D2 using an ESP32. So basically, ESP32 receives input over Wi-fi as IP data packets and pipes it to pin D2 of the Arduino. 4 motors are on default pins (3, 9, 10 and 11).
Now, so when I arm the drone all 4 motors start running/spinning. Then when I increase the throttle gradually, the motor has very erratic behavior. It starts to yaw, pitch and roll at the same time. I couldn't attach a video due to GitHub's video limit.
I've checked - the ESC, Motors and PWM are all looking error free. So my doubt comes to the MPU6050/GY521 I'm using. Does the Multiwii code calibrates the MPU6050 each time it powers on?
I calibrated the MPU6050/GY521 manually before uploading the drone code to the Arduino nano. Still behaves the same way. I tried a few different orientations of the IMU but with those, the drone doesn't even arm or at least the motors don't start spinning when armed. I was thinking to enable these 2 lines of code in my firmware -
//#define FORCE_ACC_ORIENTATION(X, Y, Z) {imu.accADC[ROLL] = Y; imu.accADC[PITCH] = -X; imu.accADC[YAW] = Z;}
//#define FORCE_GYRO_ORIENTATION(X, Y, Z) {imu.gyroADC[ROLL] = -Y; imu.gyroADC[PITCH] = X; imu.gyroADC[YAW] = Z;}
If I enable these 2 lines of code, what would be the orientation of the IMU? Also, is it possible there may be some other issue? If yes, what could it be?
Thank you very much.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.