nrf5/bluetooth: Add support for downloading s132_2.0.1 bluetooth stack.

This commit is contained in:
Glenn Ruben Bakke 2017-04-24 21:56:28 +02:00
parent 3f96532952
commit 39d3d7bb28

View File

@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
function download_s110_nrf51 function download_s110_nrf51_8_0_0
{ {
echo "" echo ""
echo "####################################" echo "####################################"
@ -8,16 +8,34 @@ function download_s110_nrf51
echo "####################################" echo "####################################"
echo "" echo ""
mkdir s110_nrf51_8.0.0 mkdir -p s110_nrf51_8.0.0
cd s110_nrf51_8.0.0 cd s110_nrf51_8.0.0
wget https://www.nordicsemi.com/eng/nordic/download_resource/45846/3/78153065/80234 wget https://www.nordicsemi.com/eng/nordic/download_resource/45846/3/78153065/80234
mv 80234 temp.zip mv 80234 temp.zip
unzip temp.zip unzip -u temp.zip
rm temp.zip rm temp.zip
cd - cd -
} }
function download_s132_nrf52 function download_s132_nrf52_2_0_1
{
echo ""
echo "####################################"
echo "### Downloading s132_nrf52_2.0.1 ###"
echo "####################################"
echo ""
mkdir -p s132_nrf52_2.0.1
cd s132_nrf52_2.0.1
wget https://www.nordicsemi.com/eng/nordic/download_resource/51479/6/84640562/95151
mv 95151 temp.zip
unzip -u temp.zip
rm temp.zip
cd -
}
function download_s132_nrf52_3_0_0
{ {
echo "" echo ""
echo "####################################" echo "####################################"
@ -25,26 +43,29 @@ function download_s132_nrf52
echo "####################################" echo "####################################"
echo "" echo ""
mkdir s132_nrf52_3.0.0 mkdir -p s132_nrf52_3.0.0
cd s132_nrf52_3.0.0 cd s132_nrf52_3.0.0
wget https://www.nordicsemi.com/eng/nordic/download_resource/56261/6/26298825/108144 wget https://www.nordicsemi.com/eng/nordic/download_resource/56261/6/26298825/108144
mv 108144 temp.zip mv 108144 temp.zip
unzip temp.zip unzip -u temp.zip
rm temp.zip rm temp.zip
cd - cd -
} }
if [ $# -eq 0 ]; then if [ $# -eq 0 ]; then
echo "No Bluetooth LE stack defined, downloading all." echo "No Bluetooth LE stack defined, downloading all."
download_s110_nrf51 download_s110_nrf51_8_0_0
download_s132_nrf52 download_s132_nrf52_2_0_1
download_s132_nrf52_3_0_0
else else
case $1 in case $1 in
"s110_nrf51" ) "s110_nrf51" )
download_s110_nrf51 ;; download_s110_nrf51_8_0_0 ;;
"s132_nrf52" ) "s132_nrf52_2_0_1" )
download_s132_nrf52 ;; download_s132_nrf52_2_0_1 ;;
"s132_nrf52_3_0_0" )
download_s132_nrf52_3_0_0 ;;
esac esac
fi fi