Skip to content

Commit

Permalink
Fixed typos
Browse files Browse the repository at this point in the history
  • Loading branch information
dooba-io committed Jan 18, 2021
1 parent 3b94194 commit 982b43b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
# owfmodules.mci.write

Write data into Memory Card through MCI interface.
8 changes: 4 additions & 4 deletions owfmodules/mci/write.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ def __init__(self, owf_config):
})
self.options = {
"start_address": {"Value": "", "Required": True, "Type": "hex",
"Description": "Address to start reading from.", "Default": 0x00},
"Description": "Address to start writing at.", "Default": 0x00},
"data_file": {"Value": "", "Required": True, "Type": "file_r",
"Description": "The file containing the data to write on the Memory Card.", "Default": ""},
"keep_existing": {"Value": "", "Required": True, "Type": "bool",
"Description": "Keep existing data if there is not enough data to fulfill a block."
"Otherwise, it will erase the rest of the block (Write 0x00).",
"Description": "Keep any pre-existing when writing incomplete blocks."
"If unset, all blocks involved will simply be erased (0x00).",
"Default": True}
}
self.dependencies.extend([
Expand Down Expand Up @@ -65,7 +65,7 @@ def write(self):
self.logger.handle("The data size exceeds the Memory Cards size", self.logger.ERROR)

# Write data
self.logger.handle("Writing file's content into the Memory Card...", self.logger.INFO)
self.logger.handle("Writing file's contents into the Memory Card...", self.logger.INFO)
with open(self.options["data_file"]["Value"], "rb") as f:
progress_bar = tqdm(initial=0, total=f_size, desc="Writing", unit='B', unit_scale=True, ascii=" #",
bar_format="{desc} : {percentage:3.0f}%[{bar}] {n_fmt}/{total_fmt}B "
Expand Down

0 comments on commit 982b43b

Please sign in to comment.