Skip to content
This repository has been archived by the owner on Jan 17, 2023. It is now read-only.

Commit

Permalink
Use warning instead of major version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
tomchy committed Sep 19, 2018
1 parent cc05f69 commit 87ad2f4
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 3 deletions.
3 changes: 1 addition & 2 deletions README.md
Expand Up @@ -32,9 +32,8 @@ that you are using you will need to select a release of this tool compatible wit

* Version 0.5.2 generates legacy firmware packages compatible with **nRF SDK 11.0 and older**
* Versions 1.5.0 and later generate modern firmware packages compatible with **nRF SDK 12.0 and newer**
* Versions 4.0.0 and later generate modern firmware packages compatible with **nRF SDK 15.1 and newer**

**Note**: In order to generate firmware images, compatible with **nRF SDK 12.0 and newer**, use `--no-backup` switch during generation of DFU settings.
**Note**: In order to generate firmware images, which does not overwrite DFU settings backup page, use `--no-backup` switch during generation of DFU settings.

## Installing from PyPI

Expand Down
22 changes: 22 additions & 0 deletions nordicsemi/__main__.py
Expand Up @@ -121,6 +121,25 @@ def display_debug_warning():
"""
click.echo("{}".format(debug_warning))

def display_settings_backup_warning():
debug_warning = """
|===============================================================|
|## ## ### ######## ## ## #### ## ## ###### |
|## ## ## ## ## ## ## ### ## ## ### ## ## ## |
|## ## ## ## ## ## ## #### ## ## #### ## ## |
|## ## ## ## ## ######## ## ## ## ## ## ## ## ## ####|
|## ## ## ######### ## ## ## #### ## ## #### ## ## |
|## ## ## ## ## ## ## ## ### ## ## ### ## ## |
| ### ### ## ## ## ## ## ## #### ## ## ###### |
|===============================================================|
|You are generating a DFU settings page with backup page |
|included. This is only required for bootloaders from nRF SDK |
|15.1 and newer. If you want to skip backup page genetation, |
|use --no-backup option. |
|===============================================================|
"""
click.echo("{}".format(debug_warning))

def int_as_text_to_int(value):
try:
if value[:2].lower() == '0x':
Expand Down Expand Up @@ -297,6 +316,9 @@ def generate(hex_file,
if no_backup is None:
no_backup = False

if no_backup == False:
display_settings_backup_warning()

if (start_address is not None) and (backup_address is None):
click.echo("WARNING: Using default offset in order to calculate bootloader settings backup page")

Expand Down
2 changes: 1 addition & 1 deletion nordicsemi/version.py
Expand Up @@ -37,4 +37,4 @@

""" Version definition for nrfutil. """

NRFUTIL_VERSION = "4.0.0"
NRFUTIL_VERSION = "3.6.0"

0 comments on commit 87ad2f4

Please sign in to comment.