dev20120225 orientation warning!!!
dev20120225 orientation warning!!!
Hi all,
I have just uploaded and tested dev20120225 and I saw that there is a serious orientation and axis change in this dev!
There are x-y axis swaps and sign changes in the specified board configs too!!!
So I recommend anybody to check the working of all sensors in GUI before taking off!!!!!
BTW, I'm using quadrino board but with separate HMC5843 so I had to consider the MAG orientations. So now everything works fine, even alt hold with MS5611 (in at least in my living room) .
BR
Adrian
I have just uploaded and tested dev20120225 and I saw that there is a serious orientation and axis change in this dev!
There are x-y axis swaps and sign changes in the specified board configs too!!!
So I recommend anybody to check the working of all sensors in GUI before taking off!!!!!
BTW, I'm using quadrino board but with separate HMC5843 so I had to consider the MAG orientations. So now everything works fine, even alt hold with MS5611 (in at least in my living room) .
BR
Adrian
-
- Posts: 178
- Joined: Fri Apr 01, 2011 10:32 pm
- Location: Czech Republic, Prague
Re: dev20120225 orientation warning!!!
Yes, I confirm that everything in sensors orientation was changed!
For me (Crius board - ITG3205,BMA180,HMC5883) worked this configuration surely test it before takeoff!
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = Z;}
Just a question - is it a purpose or just a mistake?
Roman
For me (Crius board - ITG3205,BMA180,HMC5883) worked this configuration surely test it before takeoff!
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = Z;}
Just a question - is it a purpose or just a mistake?
Roman
Last edited by rbirdie001 on Sun Feb 26, 2012 11:49 pm, edited 1 time in total.
Re: dev20120225 orientation warning!!!
This is what Alex wrote in the changes:
- sensors spec code alignment
viewtopic.php?f=8&t=1259
be careful, some errors might remain
some orientation need to be redefine in config.h for individual sensor BB
setups, but it's cleaner
So its not a mistake.
- sensors spec code alignment
viewtopic.php?f=8&t=1259
be careful, some errors might remain
some orientation need to be redefine in config.h for individual sensor BB
setups, but it's cleaner
So its not a mistake.
-
- Posts: 1630
- Joined: Wed Jan 19, 2011 9:07 pm
Re: dev20120225 orientation warning!!!
right 
It's not a mistake.
It's something I should have done months ago to ease the integration of more sensors with the right interpretation from the specs.
I know it will have some side effects for custom BB boards, but it's only a one time change.

It's not a mistake.
It's something I should have done months ago to ease the integration of more sensors with the right interpretation from the specs.
I know it will have some side effects for custom BB boards, but it's only a one time change.
Re: dev20120225 orientation warning!!!
For CRIUS SE this is in Shared:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
Change the MAG -Z to Z?
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
Change the MAG -Z to Z?
Re: dev20120225 orientation warning!!!
Hi, changes are like this:
Old:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = X; accADC[PITCH] = Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = X; gyroADC[PITCH] = Y; gyroADC[YAW] = Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = Z;}
New:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
Work with me, after broken 2 props in 2 time, not same orientation change for ACC and GYRO, but now work fine thank
Old:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = X; accADC[PITCH] = Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = X; gyroADC[PITCH] = Y; gyroADC[YAW] = Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = Z;}
New:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
Work with me, after broken 2 props in 2 time, not same orientation change for ACC and GYRO, but now work fine thank

Re: dev20120225 orientation warning!!!
Sorry, but your NEW is in the current Shared Branch. So nothing to do for me.
Re: dev20120225 orientation warning!!!
My example before was for you can see changes, you can see my personal orentations:
my old:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -Y; accADC[PITCH] = X; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = X; gyroADC[PITCH] = Y; gyroADC[YAW] = Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = -X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
my new:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = Y; accADC[PITCH] = -X; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = -X; magADC[PITCH] = Y; magADC[YAW] = Z;}
my old:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -Y; accADC[PITCH] = X; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = X; gyroADC[PITCH] = Y; gyroADC[YAW] = Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = -X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
my new:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = Y; accADC[PITCH] = -X; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = -X; magADC[PITCH] = Y; magADC[YAW] = Z;}
Re: dev20120225 orientation warning!!!
Also Miniwii with this version have wrong orientation:
Correct one is:
#if defined(MINIWII)
#define ITG3200
#define BMA180
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = X; accADC[PITCH] = -Y; accADC[YAW] = -Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#endif
Correct one is:
#if defined(MINIWII)
#define ITG3200
#define BMA180
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = X; accADC[PITCH] = -Y; accADC[YAW] = -Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#endif
Re: dev20120225 orientation warning!!!
I'm struggling with this too!
I'm using Crius board with these settings
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
Everything works as it should until the quad goes upside down. If you roll inverted, the compass heading flips 180° and if you pitch inverted the compass heading doesn't change, i.e. Quad pointing to North, roll inverted and it should still point North but instead points South. Quad pointing North and pitch inverted, heading should now be South but remains North.
All sensors show correct readings, ( roll right, mag roll, acc roll and gyro roll increase, mag Z and acc Z decrease etc) as in the faq.
I have tried every combination of orientation but none are correct. Is it me, or has the orientation been changed somewhere else in this sketch?
I have been changing it in def.h, is this correct.
I should also say that I had no problem when using 1.9.
I could do with a sanity check just so I know I haven't totally lost it!
Thanks for any help.
I'm using Crius board with these settings
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
Everything works as it should until the quad goes upside down. If you roll inverted, the compass heading flips 180° and if you pitch inverted the compass heading doesn't change, i.e. Quad pointing to North, roll inverted and it should still point North but instead points South. Quad pointing North and pitch inverted, heading should now be South but remains North.
All sensors show correct readings, ( roll right, mag roll, acc roll and gyro roll increase, mag Z and acc Z decrease etc) as in the faq.
I have tried every combination of orientation but none are correct. Is it me, or has the orientation been changed somewhere else in this sketch?
I have been changing it in def.h, is this correct.
I should also say that I had no problem when using 1.9.
I could do with a sanity check just so I know I haven't totally lost it!
Thanks for any help.
Re: dev20120225 orientation warning!!!
Have you tested the "build in" CRIUS_SE?
Sensor orientation has changed in latest DEV.
http://code.google.com/p/multiwii/sourc ... iWii/def.h
Sensor orientation has changed in latest DEV.
http://code.google.com/p/multiwii/sourc ... iWii/def.h
Re: dev20120225 orientation warning!!!
Thanks for the reply - yes, I'm using the standard Crius SE definition, and have tried pretty much everything else too.
What I don't understand is that all the sensor values are correct to the normal accepted levels as far as value change on deflection, but the orientation when inverted is not.
What I don't understand is that all the sensor values are correct to the normal accepted levels as far as value change on deflection, but the orientation when inverted is not.
Re: dev20120225 orientation warning!!!
Have just tried version 2.0 preversion_1 with default Crius SE defines and still the same. Maybe it's my board?
Hoping someone else has this board and can confirm the behaviour of theirs.
Andy
Hoping someone else has this board and can confirm the behaviour of theirs.
Andy
Re: dev20120225 orientation warning!!!
Hi,
ITG 3200's axis are inverted now
this works for me:
edit: it was -X -.-
regards felix
ITG 3200's axis are inverted now
this works for me:
Code: Select all
#if defined(ITG3200)
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#endif
edit: it was -X -.-
regards felix
Last edited by ronco on Wed Mar 07, 2012 8:23 am, edited 1 time in total.
Re: dev20120225 orientation warning!!!
Hello Dellow
Please test these settings für CRIUS_SE:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = Z;}

Please test these settings für CRIUS_SE:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = Z;}
-
- Posts: 31
- Joined: Sat Dec 31, 2011 12:10 am
Re: dev20120225 orientation warning!!!
I have updated the Page for "WMP Clone mounted on BMA020" with the orientation changes
http://fpv-community.de/wiki/index.php? ... ONE#Ablauf
http://fpv-community.de/wiki/index.php? ... ONE#Ablauf
Re: dev20120225 orientation warning!!!
Th0rsten wrote:Hello Dellow![]()
Please test these settings für CRIUS_SE:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = Z;}
I tried this change in 2.0 Pre 1 changing Y; magADC[YAW] = Z; from -Z
, It makes the compass flip 180 every 90 degree rotation on roll and pitch
Re: dev20120225 orientation warning!!!
Thanks for the reply.
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
is the correct line. SE is like the "FREEIMUv035_BMP" as I learned a few days ago.
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
is the correct line. SE is like the "FREEIMUv035_BMP" as I learned a few days ago.
Re: dev20120225 orientation warning!!!
hi,
i've been using my flyduino and FFIMUv1 now for a while on both MULTIWII and Megapirate as for me a change in Multiwiicode is way simpler to do on my own i changed the respective sensor-lines in the def.h file
reason for this, megapirate for some reason has a 90° counter-clock-wise changed orientation of the FFIMU Sensor Board.
Till now i just copied the Sensor-Orientations from the Aeroquad-Shield but as there has been some massive change that didn't work for me.
Here is the orientation i found out for a 90° CCW rotated FFIMUv1 (Megapirate compatible orientation)
what i dont understand, no mather if i use my code changes or if i have the FFIMU in its intended direction (y-dirction on the board pointing to the "front) if i ROLL the copter NORTH becomes SOUTH, if i PITCH it NORTH stays NORTH
shouldn't it be the other way round?
i don't understand this please help
kind regards
Christoph
i've been using my flyduino and FFIMUv1 now for a while on both MULTIWII and Megapirate as for me a change in Multiwiicode is way simpler to do on my own i changed the respective sensor-lines in the def.h file
reason for this, megapirate for some reason has a 90° counter-clock-wise changed orientation of the FFIMU Sensor Board.
Till now i just copied the Sensor-Orientations from the Aeroquad-Shield but as there has been some massive change that didn't work for me.
Here is the orientation i found out for a 90° CCW rotated FFIMUv1 (Megapirate compatible orientation)
Code: Select all
#if defined(FFIMUv1_90) // megapirate compatible
#define ITG3200
#define BMA180
#define BMP085
#define HMC5843
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = Y; accADC[PITCH] = -X; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = X; gyroADC[PITCH] = Y; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = -Y; magADC[PITCH] = X; magADC[YAW] = -Z;}
#define BMA180_ADDRESS 0x80
#define ITG3200_ADDRESS 0XD0
#endif
what i dont understand, no mather if i use my code changes or if i have the FFIMU in its intended direction (y-dirction on the board pointing to the "front) if i ROLL the copter NORTH becomes SOUTH, if i PITCH it NORTH stays NORTH




i don't understand this please help
kind regards
Christoph
Re: dev20120225 orientation warning!!!
Anyone using the MiniWii-Board from Jussi?
I had to change the Sensor-Orientations for the actual MW 2.0 to the following:
was:
Can anybody confirm this?
I had to change the Sensor-Orientations for the actual MW 2.0 to the following:
Code: Select all
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = -Z;}
was:
Code: Select all
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = X; accADC[PITCH] = -Y; accADC[YAW] = -Z;}
Can anybody confirm this?
Re: dev20120225 orientation warning!!!
shaddi wrote:Anyone using the MiniWii-Board from Jussi?
I had to change the Sensor-Orientations for the actual MW 2.0 to the following:Code: Select all
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = -Z;}
was:Code: Select all
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = X; accADC[PITCH] = -Y; accADC[YAW] = -Z;}
Can anybody confirm this?
Hey, look at GUI and compare it to http://www.multiwii.com/faq#How_should_be_the_sensor_axis_directions
greetz Noc
Re: dev20120225 orientation warning!!!
Yes, it works correctly. I hoped that somebody with a miniwii-board can confirm this configuration 

-
- Posts: 2
- Joined: Sat Mar 31, 2012 5:28 pm
Re: dev20120225 orientation warning!!!
Hello everyone
I was really exited and wanted to try the new version of Multiwii. I have seen that sensor orientation has been changed so that you don t have multiple orientation settings for a sensor.
But I am using a simple ITG3205 only config. After uploading I realised that the orientation is wrong now (roll/pitch movement exchanged). Is this a bug
Is this an error or do I have to change every board in my copters so that the orientation is correct again?
That would be pretty stupid.
Isn t it possible to define the ITG3200 orientation as it was before (ITG3200 as an own "sensor board")
Thanks for your help and sorry if this has already been answered
I was really exited and wanted to try the new version of Multiwii. I have seen that sensor orientation has been changed so that you don t have multiple orientation settings for a sensor.
But I am using a simple ITG3205 only config. After uploading I realised that the orientation is wrong now (roll/pitch movement exchanged). Is this a bug

Is this an error or do I have to change every board in my copters so that the orientation is correct again?
That would be pretty stupid.

Isn t it possible to define the ITG3200 orientation as it was before (ITG3200 as an own "sensor board")
Thanks for your help and sorry if this has already been answered
Re: dev20120225 orientation warning!!!
Go near the bottom of config.h and change the GYRO_ORIENTATION define to this :
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
Make sure it shows proper movement in GUI before flying .
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
Make sure it shows proper movement in GUI before flying .
-
- Posts: 2
- Joined: Sat Mar 31, 2012 5:28 pm
Re: dev20120225 orientation warning!!!
Hi Rob
Thanks for the message. Before I saw your tip, I made an own board with different gyro orientation. But your solution is much simpler.
Maybe this should be written somewhere, so that everyone can easily find it.
Thanks for the message. Before I saw your tip, I made an own board with different gyro orientation. But your solution is much simpler.
Maybe this should be written somewhere, so that everyone can easily find it.
-
- Posts: 1630
- Joined: Wed Jan 19, 2011 9:07 pm
Re: dev20120225 orientation warning!!!
It is explicitly written in Change.txt
Multiwii is not a plug&play soft
Board and sensors orientation:
This was something that was not well coded at the beginning.
viewtopic.php?f=8&t=1259
This mod should not affect board definitions (a remapping of axis was done)
About individual sensor orientation: is not the same and it’s normal,
there is no bug to correct here.
Multiwii is not a plug&play soft

-
- Posts: 1
- Joined: Fri Jun 15, 2012 4:03 pm
Re: dev20120225 orientation warning!!!
I have an y6 scorpion y650 copter and the crius se multiwii board.
the frame has an prefab mount for my board only problem is that the orientation is rotated by 45 deg.
what code do i need to reorientate the board 45 degree. It could be CCw or Cw as long as i know how to rotate.
thanks Sam
the frame has an prefab mount for my board only problem is that the orientation is rotated by 45 deg.
what code do i need to reorientate the board 45 degree. It could be CCw or Cw as long as i know how to rotate.
thanks Sam