OscP5 send and memory/timing issue
in
Contributed Library Questions
•
7 months ago
Hi. I am working on a simple LED dimmer sketch that uses ControlP5 sliders to send single byte ascii commands to a microcontroller via TCP. When I set up a client with the processing.net library and use the Client.write() command for the communication, my sketch works flawlessly. I'd like to use OscP5/NetP5 instead to get Android compatibility, but something is wrong. I can initialize the TCP connection, no problem. But as soon as I move any slider, I get an immediate OutOfMemoryError. The sketch continues to run, but only about every third or fourth controller input is received by the remote server. Changing memory allocation or frame rate has no effect. The problem only occurs when I use send, which is called by ControlEvent, outside of Draw.
Is there something obvious that would account for this? Am I missing something basic about how OscP5.send communicates? I thought it would be functionally analogous to Client.write.
Thanks for any help
Is there something obvious that would account for this? Am I missing something basic about how OscP5.send communicates? I thought it would be functionally analogous to Client.write.
Thanks for any help
1