@@ -1287,6 +1287,20 @@ FlightLogFieldPresenter.adjustDebugDefsList = function (
12871287 "debug[7]" : "Not Used" ,
12881288 } ;
12891289 }
1290+ if ( semver . gte ( firmwareVersion , '4.6.0' ) ) {
1291+ // FFT_FREQ updated in firmware #13750
1292+ DEBUG_FRIENDLY_FIELD_NAMES . FFT_FREQ = {
1293+ 'debug[all]' :'Debug FFT FREQ' ,
1294+ 'debug[0]' :'Gyro Pre Dyn Notch [dbg-axis]' ,
1295+ 'debug[1]' :'Notch 1 Center Freq [dbg-axis]' ,
1296+ 'debug[2]' :'Notch 2 Center Freq [dbg-axis]' ,
1297+ 'debug[3]' :'Notch 3 Center Freq [dbg-axis]' ,
1298+ 'debug[4]' :'Notch 4 Center Freq [dbg-axis]' ,
1299+ 'debug[5]' :'Notch 5 Center Freq [dbg-axis]' ,
1300+ 'debug[6]' :'Notch 6 Center Freq [dbg-axis]' ,
1301+ 'debug[7]' :'Notch 7 Center Freq [dbg-axis]' ,
1302+ } ;
1303+ }
12901304 }
12911305} ;
12921306
@@ -1756,13 +1770,20 @@ FlightLogFieldPresenter.decodeDebugFieldToFriendly = function (
17561770 return value . toFixed ( 0 ) ;
17571771 }
17581772 case "FFT_FREQ" :
1759- switch ( fieldName ) {
1760- case "debug[3]" : // gyro pre dyn notch [for gyro debug axis]
1761- return `${ Math . round (
1762- flightLog . gyroRawToDegreesPerSecond ( value )
1763- ) } °/s`;
1764- default :
1765- return `${ value . toFixed ( 0 ) } Hz` ;
1773+ if ( semver . gte ( flightLog . getSysConfig ( ) . firmwareVersion , '4.6.0' ) ) {
1774+ switch ( fieldName ) {
1775+ case 'debug[0]' : // gyro pre dyn notch [for gyro debug axis]
1776+ return Math . round ( flightLog . gyroRawToDegreesPerSecond ( value ) ) + " °/s" ;
1777+ default :
1778+ return value . toFixed ( 0 ) + " Hz" ;
1779+ }
1780+ } else {
1781+ switch ( fieldName ) {
1782+ case 'debug[3]' : // gyro pre dyn notch [for gyro debug axis]
1783+ return Math . round ( flightLog . gyroRawToDegreesPerSecond ( value ) ) + " °/s" ;
1784+ default :
1785+ return value . toFixed ( 0 ) + " Hz" ;
1786+ }
17661787 }
17671788 case "RTH" :
17681789 switch ( fieldName ) {
@@ -2406,13 +2427,24 @@ FlightLogFieldPresenter.ConvertDebugFieldValue = function (
24062427 return value ;
24072428 }
24082429 case "FFT_FREQ" :
2409- switch ( fieldName ) {
2410- case "debug[3]" : // gyro pre dyn notch [for gyro debug axis]
2411- return toFriendly
2412- ? flightLog . gyroRawToDegreesPerSecond ( value )
2413- : value / flightLog . gyroRawToDegreesPerSecond ( 1.0 ) ; // °/s;
2414- default :
2415- return value ;
2430+ if ( semver . gte ( flightLog . getSysConfig ( ) . firmwareVersion , '4.6.0' ) ) {
2431+ switch ( fieldName ) {
2432+ case 'debug[0]' : // gyro pre dyn notch [for gyro debug axis]
2433+ return toFriendly
2434+ ? flightLog . gyroRawToDegreesPerSecond ( value )
2435+ : value / flightLog . gyroRawToDegreesPerSecond ( 1.0 ) ; // °/s;
2436+ default :
2437+ return value ;
2438+ }
2439+ } else {
2440+ switch ( fieldName ) {
2441+ case "debug[3]" : // gyro pre dyn notch [for gyro debug axis]
2442+ return toFriendly
2443+ ? flightLog . gyroRawToDegreesPerSecond ( value )
2444+ : value / flightLog . gyroRawToDegreesPerSecond ( 1.0 ) ; // °/s;
2445+ default :
2446+ return value ;
2447+ }
24162448 }
24172449 case "RTH" :
24182450 switch ( fieldName ) {
0 commit comments