Skip to content

Commit b34c484

Browse files
committed
Some more clarifications
1 parent dd14a66 commit b34c484

File tree

3 files changed

+26
-3
lines changed

3 files changed

+26
-3
lines changed

README.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,13 +29,18 @@ Object constructor. Connects to the reader:
2929
* `"tmr:///com2"` is a typical format to connect to a serial based module on Windows COM2
3030
* `"tmr:///dev/ttyUSB0"` is a typical format to connect to a USB device named ttyUSB0 on a Unix system
3131
* `"llrp://192.198.1.100"` is a typical format to connect to an Ethernet device (works on Linux only)
32-
* *baudrate* defines the desired communication speed.
32+
* *baudrate* defines the desired communication speed of the serial port.
3333
Supported values include 110, 300, 600, 1200, 2400, 4800, 9600, 14400, 19200, 38400, 57600 and 115200 (default).
34+
This parameter is not allowed for network-connected readers.
3435

3536
For example:
3637
```python
3738
reader = mercury.Reader("tmr:///dev/ttyUSB0", baudrate=9600)
3839
```
40+
or
41+
```python
42+
reader = mercury.Reader("tmr://192.168.1.101")
43+
```
3944

4045
#### reader.get_temperature()
4146
Returns the chip temperature in degrees of Celsius.
@@ -215,8 +220,26 @@ Represents a read of an RFID tag:
215220
* *user_mem_data* contains the User bank data bytes
216221
* *reserved_mem_data* contains the Reserved bank data bytes
217222

223+
```python
224+
print(tag.epc)
225+
b'E2000087071401930700D206'
226+
print(tag.antenna)
227+
2
228+
print(tag.read_count)
229+
2
230+
print(tag.rssi)
231+
-65
232+
print(tag.user_mem_data)
233+
bytearray(b'\x00\x00\x00...')
234+
```
235+
218236
The string representation (`repr`) of the tag data is its EPC.
219237

238+
```python
239+
print(tag)
240+
b'E2000087071401930700D206'
241+
```
242+
220243
Please note that the bank data bytes need to be requested via the *bank* parameter
221244
of the reader.*set_read_plan* function. Data not requested will not be read.
222245

setup-win.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
# FIXME: make sure the patch matches the mercuryapi version you have
1111
mercuryapi = "mercuryapi-1.31.0.33/c/src/"
1212

13-
setup(name="mercuryapi", version="0.5",
13+
setup(name="mercuryapi", version="0.4.1",
1414
ext_modules=[Extension("mercury",
1515
[mercuryapi + "api/hex_bytes.c",
1616
mercuryapi + "api/llrp_reader.c",

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# python3 setup.py build
22

33
from setuptools import setup, Extension
4-
setup(name="mercuryapi", version="0.4",
4+
setup(name="mercuryapi", version="0.4.1",
55
ext_modules=[Extension("mercury",
66
sources=["mercury.c"],
77
libraries=["mercuryapi", "ltkc", "ltkctm"],

0 commit comments

Comments
 (0)