I am just trying to workout this bit of code from the roll-pitch demo.
void output_matrix(void)
// This routine makes the direction cosine matrix evident
// by setting the three servos to the three values in the
// diagonal of the matrix.
{
union longww accum ;
accum.WW = __builtin_mulss( rmat[6] , 4000 ) ;
PDC1 = 3000 + accum._.W1 ;
accum.WW = __builtin_mulss( rmat[7] , 4000 ) ;
PDC2 = 3000 + accum._.W1 ;
accum.WW = __builtin_mulss( rmat[8] , 4000 ) ;
PDC3 = 3000 + accum._.W1 ;
return ;
}
I think I understand that the rmat[6] and rmat[7] are the board pitch and roll angles in relation to the earth Z axis and that these values will be between -1 and 1.
rmat[8] is the yaw angle.
The bottom line is the PWM value sent to the servo.
I dont understand 'builtin_mulss' or the '4000' that the rmat is multiplied by.
Is my understanding right up to this point and could you help me fill in the blanks.
Is there code out there that provides roll and pitch stabilitzation without the use of a GPS? My previous experience with c programming is zero, and am really struggling with all of it.
I seem to be little late to the party and may be I don't belong to the tribe here :) I hope your project is proceeding smoothly. I am trying to build a location/attitude awareness system for an autonomous _ground_ vehicle. So there you see my vehicle needs to stay on ground unlike your birds. Essentially the system needs to be build using 6DOF IMU + GPS. While googling for ways of integrating gyro output with GPS I landed at your page. That was about two weeks back and since then I have read your DCMDraft2, this discussion topic, and several of the documentation you have put out on UAVBoard. I must congratulate you for what you have achieved and for being generous in releasing your system and code to the community.
After initial reading of UAVBoard spec I was excited that I could adapt your board to build INS/GPS system for my vehicle. Your board does a lot more things that what I need. My interest is only in these parts of the board: ability to read the gyros, acclerometers, GPS. Then use dsPIC to merge all three in your DCM, correct the errors (gyro/accel drifts) and dispatch the 3 positional and 3 orientation parameters to my computer/laptop. Basically I was thinking something like what Louis did in his wonderful video. Right now I am not interested in servo outputs, but just logging the orientation and location information as reported by the board. I dont want to control any servos/motors at the moment. The killer thing was your boards ability to read GPS radio and proper development package for dsPIC, which is important to me since my background is in CS not in ECE.
But after careful reading of the board specs, and this thread, it seems that the board was designed to be self contained and not interface with any computer. Am I correct? If that is correct, is there a way to adapt your board to my needs? Now adapt means both hardware and software. I understand the firmware needs to be modified, but is the board capable of interfacing with a laptop/computer and sending data to it using USB/RS-232 ports? Can this be done through additional hardware like ICD2 etc?
Hi,
sorry if this was already asked:
is it possible to program/debug this unit with the pic kit2 programmer?
I already had problems with it programming other devices but I fixed them downloading the latest software version (2.61)
Bill,
When I open the MatrixNav project in MPLAB, it tells me that "libdsp-coff.a" is missing. There are many versions of "libdsp.a" in the MPLAB libraries, but I cannot find that file. Can you point me in the right direction?
Thanks,
Andy
In rmat.c, in the function roll_pitch_drift, We noticed that you used the union of the longww struct so that you can take advantage of individual bytes or the entire number... When accumulating your integral, you use the lower byte as your omegacorrIAcc value.. Is that an estimate of error?
And just to clarify once again, these are all 2.14 numbers and NOT 1.15 ?
This is a great piece of electronics!
I want to change the gyros to a slightly higher 110/deg/sec (9.1mV/°/s) to cater for faster attitude changes.
If I want to use gyros with a higher rotation rate (less sensititvity), where are the gyro gain values in the "roll-pitch" demo code that I need to change?
Does the “roll-pitch demo” need the yaw gyro to be connected?
Does the board take the entire 5 seconds at startup to store the offset values for the sensors? Does it average the samples over the 5 seconds?
Dear Bill,
Is it possible to use the "UAV Dev Board" as a stabilization unit (pitch & roll ) for a r/c Helicopter / HIROBO ?
Please guide me to the relevant code / documents you have developed so that I can get familiarized with the Maths involved; I like to learn as well !
Later, I shall also like this board to used as an IMU for the same Heli.I hope this is possible too.
Sorry I am not knowledgeable enough but look forward to your guidance.
Hope to hear from you.
Sincerely,
muhammad
Abu Dhabi-United Arab Emirates
So, i've fried the 5V regulator on the board. The board still works, but at a lower MIPS.
Do you happen to know the part number for the regulator? In the hardware schematic, I believe it is labeled as U6, and it's a small 5 pin package. It sits between the dsPIC and the the pins that begin with GND, RXI, TXO, VCC.
Replies
I am just trying to workout this bit of code from the roll-pitch demo.
void output_matrix(void)
// This routine makes the direction cosine matrix evident
// by setting the three servos to the three values in the
// diagonal of the matrix.
{
union longww accum ;
accum.WW = __builtin_mulss( rmat[6] , 4000 ) ;
PDC1 = 3000 + accum._.W1 ;
accum.WW = __builtin_mulss( rmat[7] , 4000 ) ;
PDC2 = 3000 + accum._.W1 ;
accum.WW = __builtin_mulss( rmat[8] , 4000 ) ;
PDC3 = 3000 + accum._.W1 ;
return ;
}
I think I understand that the rmat[6] and rmat[7] are the board pitch and roll angles in relation to the earth Z axis and that these values will be between -1 and 1.
rmat[8] is the yaw angle.
The bottom line is the PWM value sent to the servo.
I dont understand 'builtin_mulss' or the '4000' that the rmat is multiplied by.
Is my understanding right up to this point and could you help me fill in the blanks.
Thankyou.
thanks,
mark
Thanks
I seem to be little late to the party and may be I don't belong to the tribe here :) I hope your project is proceeding smoothly. I am trying to build a location/attitude awareness system for an autonomous _ground_ vehicle. So there you see my vehicle needs to stay on ground unlike your birds. Essentially the system needs to be build using 6DOF IMU + GPS. While googling for ways of integrating gyro output with GPS I landed at your page. That was about two weeks back and since then I have read your DCMDraft2, this discussion topic, and several of the documentation you have put out on UAVBoard. I must congratulate you for what you have achieved and for being generous in releasing your system and code to the community.
After initial reading of UAVBoard spec I was excited that I could adapt your board to build INS/GPS system for my vehicle. Your board does a lot more things that what I need. My interest is only in these parts of the board: ability to read the gyros, acclerometers, GPS. Then use dsPIC to merge all three in your DCM, correct the errors (gyro/accel drifts) and dispatch the 3 positional and 3 orientation parameters to my computer/laptop. Basically I was thinking something like what Louis did in his wonderful video. Right now I am not interested in servo outputs, but just logging the orientation and location information as reported by the board. I dont want to control any servos/motors at the moment. The killer thing was your boards ability to read GPS radio and proper development package for dsPIC, which is important to me since my background is in CS not in ECE.
But after careful reading of the board specs, and this thread, it seems that the board was designed to be self contained and not interface with any computer. Am I correct? If that is correct, is there a way to adapt your board to my needs? Now adapt means both hardware and software. I understand the firmware needs to be modified, but is the board capable of interfacing with a laptop/computer and sending data to it using USB/RS-232 ports? Can this be done through additional hardware like ICD2 etc?
thanks,
Dev.
sorry if this was already asked:
is it possible to program/debug this unit with the pic kit2 programmer?
I already had problems with it programming other devices but I fixed them downloading the latest software version (2.61)
thanks!
When I open the MatrixNav project in MPLAB, it tells me that "libdsp-coff.a" is missing. There are many versions of "libdsp.a" in the MPLAB libraries, but I cannot find that file. Can you point me in the right direction?
Thanks,
Andy
In rmat.c, in the function roll_pitch_drift, We noticed that you used the union of the longww struct so that you can take advantage of individual bytes or the entire number... When accumulating your integral, you use the lower byte as your omegacorrIAcc value.. Is that an estimate of error?
And just to clarify once again, these are all 2.14 numbers and NOT 1.15 ?
Thanks,
Matthew
This is a great piece of electronics!
I want to change the gyros to a slightly higher 110/deg/sec (9.1mV/°/s) to cater for faster attitude changes.
If I want to use gyros with a higher rotation rate (less sensititvity), where are the gyro gain values in the "roll-pitch" demo code that I need to change?
Does the “roll-pitch demo” need the yaw gyro to be connected?
Does the board take the entire 5 seconds at startup to store the offset values for the sensors? Does it average the samples over the 5 seconds?
Thanks,
Matt
Is it possible to use the "UAV Dev Board" as a stabilization unit (pitch & roll ) for a r/c Helicopter / HIROBO ?
Please guide me to the relevant code / documents you have developed so that I can get familiarized with the Maths involved; I like to learn as well !
Later, I shall also like this board to used as an IMU for the same Heli.I hope this is possible too.
Sorry I am not knowledgeable enough but look forward to your guidance.
Hope to hear from you.
Sincerely,
muhammad
Abu Dhabi-United Arab Emirates
So, i've fried the 5V regulator on the board. The board still works, but at a lower MIPS.
Do you happen to know the part number for the regulator? In the hardware schematic, I believe it is labeled as U6, and it's a small 5 pin package. It sits between the dsPIC and the the pins that begin with GND, RXI, TXO, VCC.
Thanks,
Matthew
-
7
-
8
-
9
-
10
-
11
of 11 Next