Skip to content

Commit e37a396

Browse files
committed
feat: imporve log, split demo.
1 parent 7eda4de commit e37a396

File tree

17 files changed

+44
-152
lines changed

17 files changed

+44
-152
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,10 @@ pymycobot.egg-info/
55
log
66
.vscode/
77
pymycobot/__pycache__/
8+
tests/__pycache__/
89

910
test.py
1011
record.txt
1112
test_test.py
1213

13-
.DS_Store
14+
.DS_Store

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ cd <your-path>/pymycobot
4242

4343
## Usage:
4444

45-
The `tests` directory stores some test case files.
45+
The [`demo`](./demo) directory stores some test case files.
4646

4747
You can find out which interfaces pymycobot provides in `pymycobot/README.md`.
4848

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
There are some test files of **pymycobot**.
1+
There are some demo files of **pymycobot**.
22

33
`get_port.py`: output all port, choice one then write to `port.txt`, other test `.py` will read port string from `port.txt`.
Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,7 @@ def test(mycobot):
3535

3636
coords = [160, 160, 160, 0, 0, 0]
3737
mycobot.send_coords(coords, 70, 0)
38-
print("::send_coords() ==> send coords {}, speed 70, mode 0\n".format(
39-
coords))
38+
print("::send_coords() ==> send coords {}, speed 70, mode 0\n".format(coords))
4039
time.sleep(3)
4140

4241
print("::get_coords() ==> coords {}\n".format(mycobot.get_coords()))
@@ -55,7 +54,8 @@ def test(mycobot):
5554

5655

5756
if __name__ == "__main__":
58-
print("""
57+
print(
58+
"""
5959
--------------------------------------------
6060
| This file will test basic option method: |
6161
| set_led_color() |
@@ -69,7 +69,8 @@ def test(mycobot):
6969
| send_coord() |
7070
| set_free_mode() |
7171
--------------------------------------------
72-
""")
72+
"""
73+
)
7374
time.sleep(3)
7475
# port = subprocess.check_output(['echo -n /dev/ttyUSB*'],
7576
# shell=True).decode()
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)