-
Notifications
You must be signed in to change notification settings - Fork 89
Overhauling the README #301
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
06fcede
to
7e04be6
Compare
Copy edit for active voice, consistent tense and person and spelling.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bridadan This looks great. I've left a few comments and queries for you to address that I was confused about.
README.md
Outdated
```mbed-ls``` provides these points of information for all connected boards at once in a simple console (terminal) output. | ||
# mbed-ls | ||
|
||
`mbed-ls` is a Python (2 and 3) module that detects and lists Mbed Enabled devices connected to the host computer. It is delivered as a redistributable Python module (package) and command-line tool. It works on all major operating systems (Windows, Linux and Mac OS X). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Query: Who or what delivers this as a redistributable Python module (package) and command-line tool? Mbed OS? The Mbed team? Something else? Please clarify for active voice.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we change this to: Mbed LS is published by the Mbed OS team on PyPI
README.md
Outdated
Now you are ready to install mbed-ls. | ||
### Result formats | ||
|
||
The command-line is able to list the results in a number of formats. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Query: Would it be accurate to say "list the results in many formats"? If so, please change. If not, please delete "a number of".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. I would write this as: The Mbed LS command line accepts a few arguments to change the format of the results. The default format is a table. You may pass --simple
to simplify this table format, and --json
to print the table as a json list of the rows.
README.md
Outdated
|
||
To test if your installation succeeded try the ```mbedls``` command: | ||
When developing new a platform, it is possible to override the default name `mbed-ls` assigns. This is done with the `--mock` parameter: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Query: Are you (the user) doing this with the --mock
parameter, or is something else? Please clarify for active voice.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, the user uses the --mock
parameter. I would avoid the use of "default" here, as it adds no meaning.
README.md
Outdated
|
||
* Note: This feature in implicitly ON. | ||
* Note: This feature can be turned off with command line switch ```--skip-retarget```. | ||
This controls whether a unique name is assigned to each platform. The unique name takes the form of `K64F[0]`, where the number between the brackets is an incrementing value. This name is accessible through the dictionary member `platform_unique_name` in the returned platform data. It defaults to `False`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Query: Who or what assigns a unique name to each platform? You, the user? Or something else? Please clarify for active voice.
README.md
Outdated
} | ||
] | ||
``` | ||
This controls whether more data is pulled from the file system on each device. It can provide useful management data but also takes more time to execute. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Query: Who or what pulls data from the file system on each device?
README.md
Outdated
* Remove masking with '!' prefix: `$ mbedls --mock !MID` | ||
* Remove all maskings using !* notation: `$ mbedls --mock !*` | ||
* Combine above using comma (`,`) separator: `$ mbedls --mock MID1:PLATFORM_NAME1,!MID2` | ||
The name of the platform that is returned for any platform that has a `target_id` that matches the first four characters specified in `mid`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Query: Could we rewrite this for clarity? Is it saying that mid
specifies characters, and that any platform with a target_id
that matches the first four characters that mid
specifies returns its own name? Or it returns the name of a different platform?
README.md
Outdated
$ cat $HOME/.mbed-ls/.mbedls-mock | ||
{} | ||
``` | ||
All tests are contained within the `/test` directory. You can run the tests with the following command: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note to self: Change first sentence to "The /test
directory contains all tests." for active voice after responses to comments, so you don't lose comments.
README.md
Outdated
"target_id_usb_id": "0240022648cb1e77000000000000000000000000b512e3cf" | ||
} | ||
} | ||
### `mock_manufacture_id(...)` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note to self: Prefix this function call with mbeds.
just like mbeds.list_mbeds()
.
README.md
Outdated
|
||
Clone the mbed-ls repository. The following example uses the GitHub command line tools, but you can do this directly from the website: | ||
To install the `mbed-ls` module, first clone the `mbed-ls` repository. The following example uses the GitHub command-line tools, but you can do this directly from the website: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"but" -> "and/or"/delete the whole clause.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eww, not sure how this got left behind. This was from the old readme. I'll clean it up, thanks
README.md
Outdated
``` | ||
|
||
Change the directory to the mbed-ls repository directory: | ||
# Use |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this from the top level?
README.md
Outdated
$ cd mbed-ls | ||
## Command-line | ||
|
||
The command-line tool is available with the command `mbedls`: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we call out the lack of space so that people don't get confused with mbed ls
?
README.md
Outdated
Now you are ready to install mbed-ls. | ||
### Result formats | ||
|
||
The command-line is able to list the results in a number of formats. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. I would write this as: The Mbed LS command line accepts a few arguments to change the format of the results. The default format is a table. You may pass --simple
to simplify this table format, and --json
to print the table as a json list of the rows.
README.md
Outdated
|
||
To test if your installation succeeded try the ```mbedls``` command: | ||
When developing new a platform, it is possible to override the default name `mbed-ls` assigns. This is done with the `--mock` parameter: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, the user uses the --mock
parameter. I would avoid the use of "default" here, as it adds no meaning.
README.md
Outdated
|
||
Example TargetID coding: | ||
* Freescale `K64F` TargetID: `0240000033514e450019500585d40008e981000097969900` | ||
The Python API is available through the `mbed_lstools` module. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you move this sentence into the Python API
heading?
README.md
Outdated
|
||
We can see the mounting result in the usb-id directories in Ubuntu's file system under ```/dev/```. To list mbed boards mounted to serial ports (CDC) via USB, we use the general Linux command: | ||
If set to `True`, this skips the retargetting step, and the results are unmodified. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe mention the connection to --skip-retarget
?
README.md
Outdated
lrwxrwxrwx root 13 Feb 19 12:35 usb-STMicroelectronics_STM32_STLink_066EFF525257775087141721-if02 -> ../../ttyACM2 | ||
lrwxrwxrwx root 13 Feb 19 12:35 usb-STMicroelectronics_STM32_STLink_066EFF534951775087215736-if02 -> ../../ttyACM1 | ||
``` | ||
If set to `True`, this includes unmounted platforms in the results. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mention the connection to -u
?
README.md
Outdated
|
||
From this we know that the target platform has these properties: | ||
- `FSInteraction.NEVER` - This is the fastest option but also potentially the least accurate. It never touches the file system of the devices and uses only the information available through the OS. This is appropriate for use in a highly controlled environment (such as an automated Continuous Integration setup). **This has the potential to provide incorrect names and data. It may also lead to devices not being detected at all.** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: the filesystem is available through the OS. Could you rewrite "OS" to "USB descriptors"?
README.md
Outdated
* The unique target platform identifier is ```066E```. | ||
* The serial port is ```ttyACM2```. | ||
* The mount point is ```sdd```. | ||
##### `filter_function` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you move this above fs_interaction
?
Ok, all edits implemented! It might be a good idea to do one more once over. I hadn't realized you had pushed to my fork @AnotherButler so I had to rebase my edits, so hopefully I didn't mess up your awesome work! |
Copy edit file for active voice, consistent tense and minor grammar fixes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Nice work on this
README.md
Outdated
@@ -245,13 +245,13 @@ This argument controls the accuracy and speed of this function. There are three | |||
|
|||
**Default:** `False`. | |||
|
|||
Mbed LS will assign a unique name to each platform if this is set to `True`. The unique name takes the form of `K64F[0]`, where the number between the brackets is an incrementing value. This name is accessible through the dictionary member `platform_unique_name` in the returned platform data. | |||
Mbed LS assigns a unique name to each platform if this is set to `True`. The unique name takes the form of `K64F[0]`, where the number between the brackets is an incrementing value. This name is accessible through the dictionary member `platform_unique_name` in the returned platform data. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if -> when?
README.md
Outdated
|
||
#### `read_details_txt` | ||
|
||
**Default:** `False` | ||
|
||
Mbed LS will pull more data from the files ystem on each device if this is set to `True`. It can provide useful management data, but also takes more time to execute. | ||
Mbed LS pulls more data from the file system on each device if this is set to `True`. It can provide useful management data but also takes more time to execute. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pulls -> reads.
Thanks for the changes @AnotherButler and the review @theotherjimmy. I pushed up some changes. |
Looks good @bridadan |
This is loooooong overdue! I had to put this up in a rush, so apologies for the typos. Just let me know and I'll fix them!
Could you please take a look @AnotherButler? Thanks!