# Igntion vision 8.1

**URL:** <https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678>\
**Category:** Ignition\
**Tags:** ignition81, vision\
**Created:** [March 26, 2022, 6:12pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678 "2022-03-26T18:12:46Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Esme\_Lopez](https://avatars.discourse-cdn.com/v4/letter/e/ecb155/32.png) [@Esme\_Lopez](https://forum.inductiveautomation.com/u/Esme_Lopez)\
**Post date:** [March 26, 2022, 6:12pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678/1 "2022-03-26T18:12:46Z")

</div>

I have this:  
writeBytes([\x01])  
If I write a byte in hexadecimal I should receive the same ,but why the response is 127.  
Can anyone tell me, please?

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [March 26, 2022, 6:18pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678/2 "2022-03-26T18:18:50Z")

</div>

Sorry, you’ll need to provide a little more detail about what you’re doing.

---

<div class="post-metadata">

**Author:** ![Esme\_Lopez](https://avatars.discourse-cdn.com/v4/letter/e/ecb155/32.png) [@Esme\_Lopez](https://forum.inductiveautomation.com/u/Esme_Lopez)\
**Post date:** [March 26, 2022, 6:21pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678/3 "2022-03-26T18:21:13Z")

</div>

![WhatsApp Image 2022-03-26 at 12.19.53 PM (1)](https://us1.discourse-cdn.com/inductiveautomation/original/3X/4/b/4be198df08caf46134b1ffbd016597000bd093f2.jpeg)

This is where I am writing the byte

---

<div class="post-metadata">

**Author:** ![Esme\_Lopez](https://avatars.discourse-cdn.com/v4/letter/e/ecb155/32.png) [@Esme\_Lopez](https://forum.inductiveautomation.com/u/Esme_Lopez)\
**Post date:** [March 26, 2022, 6:21pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678/4 "2022-03-26T18:21:56Z")

</div>

And here I am reading and getting the 127

 ![WhatsApp Image 2022-03-26 at 12.19.53 PM](https://us1.discourse-cdn.com/inductiveautomation/original/3X/6/6/6657d9bff4e18c91c7c4c3b0a00e686b4c545ce5.jpeg)

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [March 26, 2022, 6:28pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678/5 "2022-03-26T18:28:39Z")

</div>

Tip: please copy the **code** from your screen and post it using the `</>` **code formatting button**. That way we can copy and paste and edit it in our answers.

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [March 26, 2022, 6:31pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678/6 "2022-03-26T18:31:29Z")

</div>

One problem you have is `stopBis`. It should be `stopBits`.

---

<div class="post-metadata">

**Author:** ![Esme\_Lopez](https://avatars.discourse-cdn.com/v4/letter/e/ecb155/32.png) [@Esme\_Lopez](https://forum.inductiveautomation.com/u/Esme_Lopez)\
**Post date:** [March 26, 2022, 6:42pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678/7 "2022-03-26T18:42:49Z")

</div>

I am using an interface USB to SR485  
The ports, I am using a converter

```auto

import time 
with system.serial.port(
port = "COM3",
bitrate = system.serial.BIT.RATE_19200,
databits = system.serial.DATA.BITS_8,
handshake = system.HANDSHAKE_NONE,
hardwareFlowControl = False,
parity = system.serial.PARITY_MARK,
stopBits = system.serial.STOP_BITS_1) as portOutAddress:

portOutAddress.writeBytes([\x01])
time.sleep(0.1)

with system.serial.port(
port="COM9",
bitrate = system.serial.BIT.RATE_19200,
databits = system.serial.DATA.BITS_8,
handshake = system.HANDSHAKE_NONE,
hardwareFlowControl = False,
parity= system.serial.PARITY_NONE,
stopbits = system.serial.STOP_BITS_1) as port:
L= port.readBytes(1, 10000)
print L

```

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [March 26, 2022, 7:07pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678/8 "2022-03-26T19:07:50Z")

</div>

Your erroneous transcription and screenshots also use `bitrate` instead of `bitRate` for the parameter.

See [system.serial.port - Ignition User Manual 8.1 - Ignition Documentation](https://docs.inductiveautomation.com/display/DOC81/system.serial.port) for the parameter names.

I think you may have a configuration or hardware issue. I don’t have any real hardware to test with, but it seems fine with a pair of virtual ports:

```python
import time

with system.serial.port(
	port = "/tmp/vserial33",
	bitRate = system.serial.BIT_RATE_38400) as p1:
	
    p1.writeBytes([\x01])

time.sleep(0.1)

with system.serial.port(
	port = "/tmp/vserial44",
	bitRate = system.serial.BIT_RATE_38400) as p2:
	
    print p2.readBytes(1, 1000)

```

Output:

```auto
>>> 
array('b', [1])
>>> 

```

---

<div class="post-metadata">

**Author:** ![Esme\_Lopez](https://avatars.discourse-cdn.com/v4/letter/e/ecb155/32.png) [@Esme\_Lopez](https://forum.inductiveautomation.com/u/Esme_Lopez)\
**Post date:** [March 26, 2022, 7:13pm UTC](https://forum.inductiveautomation.com/t/igntion-vision-8-1/57678/9 "2022-03-26T19:13:31Z")

</div>

Let me check the hardware, I changed bitrate for bitRate, thanks
