Edited by odtu_ee, 17 July 2011 - 05:55 PM.
a question about ahrs
Started by odtu_ee, Jul 17 2011 05:26 PM
7 replies to this topic
#1
Posted 17 July 2011 - 05:26 PM
There is both an attitude and an ahrs module in the source codes. Which one is being used in the current coptercontrol card to generate "CurrentAttitude" input for the stabilization module?
#2
Posted 17 July 2011 - 06:12 PM
Coptercontrol uses the attitude module, the beta version of the pro platform uses the ahrs module. For a list of the modules used check the makefiles.
Life is just a game, but atleast the graphics are awesome!
#3
Posted 17 July 2011 - 07:32 PM
which branch in the git is for the pro platform?
#4
Posted 17 July 2011 - 08:20 PM
We don't use different branches for different platforms - master has all code for both CC and Pro.
Branches in git are development ones used for some features. After some feature is complete - that branch will be merged into the master.
CopterControl uses Attitude module.
OpenPilot Pro uses AHRSComms module which updates the attitude from separate AHRS board. That board has its own code located in filght/AHRS/ directory.
Branches in git are development ones used for some features. After some feature is complete - that branch will be merged into the master.
CopterControl uses Attitude module.
OpenPilot Pro uses AHRSComms module which updates the attitude from separate AHRS board. That board has its own code located in filght/AHRS/ directory.
#5
Posted 17 July 2011 - 11:30 PM
I wish you had connected the gps and mags to the AHRS card directly in your pro-platform. With such configuration it would be much easier to use AHRS card as a standalone vehicle or pedestrian navigation unit.
#6
Posted 18 July 2011 - 01:00 AM
On the Pro it is. The Mag is on the INS card and the GPS connects directly to that.
The AHRS hardware is fairly old now and was never released, it just stayed as beta.
The AHRS hardware is fairly old now and was never released, it just stayed as beta.
#7
Posted 19 July 2011 - 07:18 AM
I am stucked on a strange question. I could not figure out which function is used on AHRS card to send data to OP.
As far as I can follow here is the program flow:
1. send_attitude() calls AhrsSetData()
2. AhrsSetData() marks the object as dirty using SetObjectDirty()
3. HandleObjectPacket() calls FillObjectPacket()
4. FillObjectPacket() adds each dirty object to "txPacket"
However after this, no function sends this "txPacket" over spi to OP.
SendPacket() is used to send "txPacket" on the OP card. However, "SendPacket" is not defined for "IN_AHRS".
My question is which function on the ahrs side sends the data to the OP part?
Any help is appreciated.
As far as I can follow here is the program flow:
1. send_attitude() calls AhrsSetData()
2. AhrsSetData() marks the object as dirty using SetObjectDirty()
3. HandleObjectPacket() calls FillObjectPacket()
4. FillObjectPacket() adds each dirty object to "txPacket"
However after this, no function sends this "txPacket" over spi to OP.
SendPacket() is used to send "txPacket" on the OP card. However, "SendPacket" is not defined for "IN_AHRS".
My question is which function on the ahrs side sends the data to the OP part?
Any help is appreciated.
#8
Posted 19 July 2011 - 07:41 AM
IIRC (it's been a while) AHRSPoll on the AHRS side will preload the spi buffer with the next packet. However the AHRS is a slave device so the OP side is what initiates the transfer from the loop in the AHRSComms module.



Turkey
Portugal
Ukraine
Australia
United States







