Skip to content

Commit ffdd115

Browse files
Merge pull request #1 from mindwidgets/fix-missing-bytearray-encoding
Fix missing encoding from bytearray use
2 parents 9fd3a23 + 0ff6807 commit ffdd115

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

.github/workflows/build.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,11 @@ jobs:
2222
awk -F '\/' '{ print tolower($2) }' |
2323
tr '_' '-'
2424
)
25-
- name: Set up Python 3.x
25+
- name: Set up Python 3.11
26+
# Hard code to 3.11 to fix setuptools bug in 3.12
2627
uses: actions/setup-python@v2
2728
with:
28-
python-version: "3.x"
29+
python-version: "3.11"
2930
- name: Versions
3031
run: |
3132
python3 --version

.readthedocs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
version: 2
1010

1111
build:
12-
os: ubuntu-20.04
12+
os: ubuntu-latest
1313
tools:
1414
python: "3"
1515

mindwidgets_df1201s.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ def _send_query(self, command: str, arg=None) -> str:
105105
print("DFPlayer Command: ", at_command)
106106

107107
# send the AT command
108-
self._uart.write(bytearray(f"{at_command}\r\n"))
108+
self._uart.write(bytearray(f"{at_command}\r\n", "ascii"))
109109

110110
# read the response and strip the \r\n
111111
response = self._uart.readline()

0 commit comments

Comments
 (0)