diff --git a/Compile-Betaflight.ps1 b/Compile-Betaflight.ps1 new file mode 100644 index 0000000..677cfb6 --- /dev/null +++ b/Compile-Betaflight.ps1 @@ -0,0 +1,170 @@ +<# +Use this to create .hex files from Betaflight Code. + +1. Install Docker Desktop +2. Clone Betaflight repo "https://github.com/betaflight/betaflight" +3. Use this script to compile .hex/.bin files + +Created by: Ted Elmenheim, 2021-01-18 + +#> + +#Clone/Download the betaflight repo you want. +$workdir = "C:\GITHUB\betaflight-3.5.6\betaflight" #Path to your betaflight repo + +#Add/remove the Flightcontrollers you need +$FlightControllers = @( +"AG3X" #Add one Flightcontroller per line +"AIKONF4" +"AIR32" +"AIRBOTF7" +"AIRF7" +"AIRHEROF3" +"ALIENFLIGHTF1" +"ALIENFLIGHTF3" +"ALIENFLIGHTF4" +"ALIENFLIGHTNGF7" +"ALIENWHOOP" +"ANYFCF7" +"ANYFCM7" +"BEEBRAIN_V2F" +"BEEROTORF4" +"BETAFLIGHTF3" +"BETAFLIGHTF4" +"BLUEJAYF4" +"CC3D" +"CHEBUZZF3" +"CJMCU" +"CLRACINGF4" +"CLRACINGF7" +"COLIBRI" +"COLIBRI_RACE" +"CRAZYBEEF3FR" +"CRAZYFLIE2" +"DALRCF405" +"DALRCF722DUAL" +"DOGE" +"EACHIF3" +"ELINF722" +"ELLE0" +"EXF722DUAL" +"F4BY" +"FF_FORTINIF4" +"FF_PIKOBLX" +"FF_PIKOF4" +"FF_RACEPIT" +"FISHDRONEF4" +"FLYWOOF411" +"FLYWOOF7DUAL" +"FOXEERF405" +"FOXEERF722DUAL" +"FRSKYF3" +"FRSKYF4" +"FURYF3" +"FURYF4" +"HAKRCF405" +"HAKRCF411" +"HAKRCF722" +"IFLIGHT_H743_AIO" +"IFLIGHT_H7_TWING" +"IMPULSERCF3" +"IRCFUSIONF3" +"ISHAPEDF3" +"JHEF7DUAL" +"KAKUTEF4" +"KAKUTEF7" +"KISSFC" +"KISSFCV2F7" +"KIWIF4" +"KROOZX" +"LUMBAF3" +"LUXMINIF7" +"LUX_RACE" +"MAMBAF411" +"MAMBAF722" +"MATEKF405" +"MATEKF411" +"MATEKF411RX" +"MATEKF722" +"MATEKF722SE" +"MATEKH743" +"MERAKRCF405" +"MERAKRCF722" +"MICROSCISKY" +"MIDELICF3" +"MOTOLAB" +"MOTOLABF4" +"MULTIFLITEPICO" +"NAZE" +"NERO" +"NOX" +"NUCLEOF103RG" +"NUCLEOF303RE" +"NUCLEOF446RE" +"NUCLEOF7" +"NUCLEOF722" +"NUCLEOH723ZG" +"NUCLEOH725ZG" +"NUCLEOH743" +"NUCLEOH7A3ZI" +"OMNIBUS" +"OMNIBUSF4" +"OMNIBUSF4FW" +"OMNIBUSF4NANOV7" +"OMNIBUSF7" +"OMNIBUSF7NANOV7" +"OMNINXT" +"PYRODRONEF4" +"RACEBASE" +"RCEXPLORERF3" +"REVO" +"REVOLT" +"REVONANO" +"RG_SSD_F3" +"RUSHCORE7" +"SINGULARITY" +"SIRINFPV" +"SITL" +"SKYZONEF405" +"SPARKY" +"SPARKY2" +"SPEEDYBEEF4" +"SPEEDYBEEF7" +"SPEKTRUMF400" +"SPRACINGF3" +"SPRACINGF3EVO" +"SPRACINGF3MINI" +"SPRACINGF3NEO" +"SPRACINGF4EVO" +"SPRACINGF4NEO" +"SPRACINGF7DUAL" +"SPRACINGH7EXTREME" +"SPRACINGH7NANO" +"SPRACINGH7ZERO" +"STM32F3DISCOVERY" +"STM32F411DISCOVERY" +"STM32F4DISCOVERY" +"STM32_UNIFIED" +"TINYFISH" +"TMOTORF4" +"TMOTORF7" +"TRANSTECF411" +"TRANSTECF7" +"UAVPNG030MINI" +"VGOODRCF4" +"VRRACE" +"WORMFC" +"XILOF4" +"X_RACERSPI" +"YUPIF4" +"YUPIF7" +) + +#No need to edit anything beyond this point +Foreach($FlightController in $FlightControllers){ + + $target = "TARGET=$($FlightController)" + $workdir = "$($workdir):/opt/betaflight" + docker run -e $($target) --rm -ti -v $workdir betaflight/betaflight-build +} +