You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

64 lines
1.7 KiB

2 years ago
1 year ago
2 years ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
1 year ago
  1. @echo off
  2. @REM ����app
  3. call scripter\keil_build.bat app\app.uvprojx app\_build\app.hex
  4. md output
  5. del output\app_whole.hex
  6. del output\app.zip
  7. del output\oximeter_ble_client.zip
  8. del output\oximeter_ble_client.hex
  9. @REM �����Ƿ������ɹ�
  10. if not exist app\_build\app.hex (
  11. echo ����appʧ��
  12. exit /b 1
  13. )
  14. @REM ����app.hex �� output\
  15. copy /y app\_build\app.hex output\app.hex
  16. @REM ����setting page
  17. echo ---------------------------------------------------------------
  18. echo - generate settings.hex
  19. echo ---------------------------------------------------------------
  20. scripter\nrfutil settings generate ^
  21. --family NRF52 ^
  22. --application output/app.hex ^
  23. --application-version 1 ^
  24. --bootloader-version 1 ^
  25. --bl-settings-version 2 output/settings.hex
  26. echo ---------------------------------------------------------------
  27. echo - done
  28. echo ---------------------------------------------------------------
  29. @REM ����Զ����������
  30. scripter\nrfutil pkg generate ^
  31. --application output\app.hex ^
  32. --application-version 1 ^
  33. --hw-version 52 ^
  34. --sd-req 0x0100 ^
  35. --key-file pemkey\priv.pem output\app.zip
  36. if %errorlevel% neq 0 (
  37. echo EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE
  38. echo E ����������ʧ�� E
  39. echo EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE
  40. exit /b 1
  41. )
  42. @REM �������徵��
  43. mergehex --merge res/bootloader.hex output/settings.hex --output output/bl_temp.hex
  44. mergehex --merge output/bl_temp.hex output/app.hex res/s140_nrf52_7.2.0_softdevice.hex --output output/app_whole.hex
  45. del output\bl_temp.hex
  46. del output\settings.hex
  47. del output\app.hex
  48. copy /y output\app.zip output\oximeter_ble_client.zip
  49. copy /y output\app_whole.hex output\oximeter_ble_client.hex