# Udp problem sending byte (-127)

**URL:** <https://discourse.processing.org/t/udp-problem-sending-byte-127/3545>\
**Category:** Electronics (Arduino, etc.)\
**Created:** [September 15, 2018, 6:06am UTC](https://discourse.processing.org/t/udp-problem-sending-byte-127/3545 "2018-09-15T06:06:01Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![tuxilus](https://avatars.discourse-cdn.com/v4/letter/t/839c29/32.png) [@tuxilus](https://discourse.processing.org/u/tuxilus)\
**Post date:** [September 15, 2018, 6:06am UTC](https://discourse.processing.org/t/udp-problem-sending-byte-127/3545/1 "2018-09-15T06:06:01Z")

</div>

Hello,  
I am trying to send visca commands over udp.  
To send a command to camera 1 you have to send byte (0x81).  
Unfortunately udp.send sends the value 63!  
I discovered this by sending from processing 3 on windows and I am receiving with processing on a raspberry pi with processing 3

byte[] mist = {byte(80),byte(0x81), byte(0x82), byte(0x83), byte(0x84), byte(0x85), byte(0xFF)};  
String massage=new String(mist);  
udp.send(massage, ip, port);

results on the receiver side to  
-128, 63, -126,-125 etc…

In whatever way I am building the bytes, the result is always the same -127 results on the receiver side to 63.

Is there anywhere a guru who can tell me where i can patch the library?

Thanks a lot.  
Horst

---

<div class="post-metadata">

**Author:** ![GoToLoop](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/gotoloop/32/86_2.png) [@GoToLoop](https://discourse.processing.org/u/GoToLoop)\
**Post date:** [September 15, 2018, 6:16am UTC](https://discourse.processing.org/t/udp-problem-sending-byte-127/3545/2 "2018-09-15T06:16:05Z")

</div>

Can’t you simply **send()** the _byte[]_ array instead of a String? 🤔  
`udp.send(mist, ip, port);`

[UBAA.net/shared/processing/udp/udp\_method\_send.htm](http://UBAA.net/shared/processing/udp/udp_method_send.htm)

---

<div class="post-metadata">

**Author:** ![tuxilus](https://avatars.discourse-cdn.com/v4/letter/t/839c29/32.png) [@tuxilus](https://discourse.processing.org/u/tuxilus)\
**Post date:** [September 15, 2018, 6:41am UTC](https://discourse.processing.org/t/udp-problem-sending-byte-127/3545/3 "2018-09-15T06:41:32Z")

</div>

I did as you told me.

I am sending this from another raspberry1 to raspberry2

It works !!!

byte[] mist = {byte(0x80),byte(0x81), byte(0x82), byte(0x83), byte(0x84), byte(0x85), byte(0xFF)};  
udp.send(mist, ip, port);

receive: “�������” from 192.168.200.186 on port 45759  
[0] -128  
[1] -127  
[2] -126  
[3] -125  
[4] -124  
[5] -123  
[6] -1

Thank you very much.  
My cam is positioning.
