# Electronics (Arduino, etc.)

**URL:** https://discourse.processing.org/c/processing/processing-electronics/25.md?page=15

[Latest](https://discourse.processing.org/latest.md) · [Categories](https://discourse.processing.org/categories.md) · [Tags](https://discourse.processing.org/tags.md)

**Page:** 16

---

## [Lose data from serial port](https://discourse.processing.org/t/lose-data-from-serial-port/17697)

<div class="topic-metadata">

**Author:** [@lzwang26](https://discourse.processing.org/u/lzwang26)\
**Replies:** 4\
**Last updated:** [February 12, 2020, 7:41pm UTC](https://discourse.processing.org/t/lose-data-from-serial-port/17697 "2020-02-12T19:41:48Z")

</div>

I’m trying to send data from Arduino to Processing. Three data are sent by Arduino which separated by comma (like 616, 224, 1200), and is split and stored. The data can be read and printed by Arduino Serial monitor prope…

---

## [Cannot do if/else statement with Arduino PIR motion sensor](https://discourse.processing.org/t/cannot-do-if-else-statement-with-arduino-pir-motion-sensor/17679)

<div class="topic-metadata">

**Author:** [@arduinonoob](https://discourse.processing.org/u/arduinonoob)\
**Replies:** 3\
**Last updated:** [February 10, 2020, 11:15pm UTC](https://discourse.processing.org/t/cannot-do-if-else-statement-with-arduino-pir-motion-sensor/17679 "2020-02-10T23:15:02Z")

</div>

Project overview: I am connecting an Arduino to processing because I want to speed up/speed down a video through LOW/HIGH on the motion sensor. When the motion sensor detects movement, I need the speed of the video to sl…

---

## [Playing video with PIR motion sensor](https://discourse.processing.org/t/playing-video-with-pir-motion-sensor/8214)

<div class="topic-metadata">

**Author:** [@kud7](https://discourse.processing.org/u/kud7)\
**Replies:** 11\
**Last updated:** [February 10, 2020, 3:25am UTC](https://discourse.processing.org/t/playing-video-with-pir-motion-sensor/8214 "2020-02-10T03:25:18Z")

</div>

Processing sketch working great, which i can play video from hdd and PIR motion sensor detect my motion but actually i want to trigger video or Processing sketch from with PIR motion sensor. I also tested motion sensor w…

---

## [PIR motion sensor, Arduino, Processing, not working](https://discourse.processing.org/t/pir-motion-sensor-arduino-processing-not-working/17655)

<div class="topic-metadata">

**Author:** [@arduinonoob](https://discourse.processing.org/u/arduinonoob)\
**Replies:** 4\
**Last updated:** [February 9, 2020, 4:13pm UTC](https://discourse.processing.org/t/pir-motion-sensor-arduino-processing-not-working/17655 "2020-02-09T16:13:11Z")

</div>

I need help asap please Hello, I am trying to get a mp4 video to play in processing whenever motion is detected in Arduino and then I need it to pause when motion ends. I am a student and I have been trying for 10 hours…

---

## [Check For USB Port Connection](https://discourse.processing.org/t/check-for-usb-port-connection/17406)

<div class="topic-metadata">

**Author:** [@fredstout](https://discourse.processing.org/u/fredstout)\
**Replies:** 21\
**Last updated:** [February 4, 2020, 6:43pm UTC](https://discourse.processing.org/t/check-for-usb-port-connection/17406 "2020-02-04T18:43:34Z")

</div>

My sketch seems to work well unless I forget to plug in the USB-based input (Arduino). If I fail to connect the USB, my sketch fails in a most ungracious manner(appears to lockup in a loop). Can someone help with the c…

---

## [Display information from Arduino Serial Monitor](https://discourse.processing.org/t/display-information-from-arduino-serial-monitor/17439)

<div class="topic-metadata">

**Author:** [@jaxx2009](https://discourse.processing.org/u/jaxx2009)\
**Replies:** 2\
**Last updated:** [January 31, 2020, 9:07pm UTC](https://discourse.processing.org/t/display-information-from-arduino-serial-monitor/17439 "2020-01-31T21:07:58Z")

</div>

From what I understand, you can’t have processing functioning at 100% while the Arduino serial monitor is open. The Arduino serial monitor has some information that I need to be able to see written to it, is there a way …

---

## [Some problem with the code execution screen](https://discourse.processing.org/t/some-problem-with-the-code-execution-screen/17102)

<div class="topic-metadata">

**Author:** [@leonardorocha](https://discourse.processing.org/u/leonardorocha)\
**Replies:** 4\
**Last updated:** [January 30, 2020, 1:17am UTC](https://discourse.processing.org/t/some-problem-with-the-code-execution-screen/17102 "2020-01-30T01:17:16Z")

</div>

Hi guys, I having some problems to execute a code. When I click on button Run nothing happens. Someone knows what is going on?

---

## [Arduino, piezo sensors and Processing animations](https://discourse.processing.org/t/arduino-piezo-sensors-and-processing-animations/17255)

<div class="topic-metadata">

**Author:** [@EasyJu](https://discourse.processing.org/u/EasyJu)\
**Replies:** 5\
**Last updated:** [January 29, 2020, 1:24pm UTC](https://discourse.processing.org/t/arduino-piezo-sensors-and-processing-animations/17255 "2020-01-29T13:24:15Z")

</div>

Hi everyone, (french version below) I’m working on a project with Arduino, piezo sensors and Processing. I would like to have an animation played on Processing for each time a sensor is activated (an animation for a se…

---

## [java.lang.UnsatisfiedLinkError](https://discourse.processing.org/t/java-lang-unsatisfiedlinkerror/16848)

<div class="topic-metadata">

**Author:** [@spflanze](https://discourse.processing.org/u/spflanze)\
**Replies:** 9\
**Last updated:** [January 28, 2020, 5:22am UTC](https://discourse.processing.org/t/java-lang-unsatisfiedlinkerror/16848 "2020-01-28T05:22:23Z")

</div>

I am developing a Processing Sketch in Eclipse that uses USB by means of the serial port emulator in jssc.jar. It charts data received over the serial port as lines on a graph. When the program is run, the sketch window …

---

## [Connect to a serial port without it crashing if the device isn't connected?](https://discourse.processing.org/t/connect-to-a-serial-port-without-it-crashing-if-the-device-isnt-connected/17290)

<div class="topic-metadata">

**Author:** [@pmorgan4801](https://discourse.processing.org/u/pmorgan4801)\
**Replies:** 3\
**Last updated:** [January 24, 2020, 9:38pm UTC](https://discourse.processing.org/t/connect-to-a-serial-port-without-it-crashing-if-the-device-isnt-connected/17290 "2020-01-24T21:38:26Z")

</div>

Hello, I am new to processing and am trying to connect processing 3 to an Arduino Nano. I am able to get it connected successfully through the standard means: import processing.serial.\*; void setup(){ port = new Seri…

---

## [Arduino - processing: serial data to toggle mp3 file in minim](https://discourse.processing.org/t/arduino-processing-serial-data-to-toggle-mp3-file-in-minim/17068)

<div class="topic-metadata">

**Author:** [@clara\_h](https://discourse.processing.org/u/clara_h)\
**Replies:** 9\
**Last updated:** [January 16, 2020, 11:48am UTC](https://discourse.processing.org/t/arduino-processing-serial-data-to-toggle-mp3-file-in-minim/17068 "2020-01-16T11:48:50Z")

</div>

Hi, I’m sending data through the serial port to toggle a sound file on and off in minim. The string data is all being read correctly in Processing, but the code isn’t accessing the if loops for some reason?? here’s th…

---

## [splitTokens() question](https://discourse.processing.org/t/splittokens-question/17076)

<div class="topic-metadata">

**Author:** [@pandl](https://discourse.processing.org/u/pandl)\
**Replies:** 4\
**Last updated:** [January 15, 2020, 4:15am UTC](https://discourse.processing.org/t/splittokens-question/17076 "2020-01-15T04:15:30Z")

</div>

Thank you for reading this. The following is a section from a piece of code that I copied for an Internet project. It fails with an exception error on the line float hum = float(list\[1\]);. Some Internet searching reveal…

---

## [Collision detection issues](https://discourse.processing.org/t/collision-detection-issues/17009)

<div class="topic-metadata">

**Author:** [@gibbo7997](https://discourse.processing.org/u/gibbo7997)\
**Replies:** 14\
**Last updated:** [January 14, 2020, 4:56pm UTC](https://discourse.processing.org/t/collision-detection-issues/17009 "2020-01-14T16:56:32Z")

</div>

Hi guys, currently working on a uni project where we have to incorporate a piece of hardware into our code. I have tried to create a code based on the flappy bird game and found someone who had created a ‘flappy code’ ga…

---

## [Reading byte array into float (expanding on SerialCallResponse example)](https://discourse.processing.org/t/reading-byte-array-into-float-expanding-on-serialcallresponse-example/16880)

<div class="topic-metadata">

**Author:** [@julianop](https://discourse.processing.org/u/julianop)\
**Replies:** 18\
**Last updated:** [January 13, 2020, 4:28pm UTC](https://discourse.processing.org/t/reading-byte-array-into-float-expanding-on-serialcallresponse-example/16880 "2020-01-13T16:28:06Z")

</div>

An old C programmer, I’m new to Processing (and not particularly skilled at C++, come to that…), so naturally I’m banging up against the stronger type discipline of Object Oriented languages, and could use a spot of help…

---

## [Problem i face in serial communication](https://discourse.processing.org/t/problem-i-face-in-serial-communication/17023)

<div class="topic-metadata">

**Author:** [@Cyjian](https://discourse.processing.org/u/Cyjian)\
**Replies:** 5\
**Last updated:** [January 12, 2020, 3:27am UTC](https://discourse.processing.org/t/problem-i-face-in-serial-communication/17023 "2020-01-12T03:27:59Z")

</div>

Hi, i am learning the serial communication by using the Arduino collect the data and use the processing to do a GUI to display the data. Here is my Arduino code and Processing code. Arduino #include \<Servo.h\> Servo mys…

---

## [Problem Saving Serial data into an Array](https://discourse.processing.org/t/problem-saving-serial-data-into-an-array/17003)

<div class="topic-metadata">

**Author:** [@hachimbala](https://discourse.processing.org/u/hachimbala)\
**Replies:** 3\
**Last updated:** [January 11, 2020, 3:40pm UTC](https://discourse.processing.org/t/problem-saving-serial-data-into-an-array/17003 "2020-01-11T15:40:18Z")

</div>

Hello, I am developing an Arduino 360 radar, my arduino is sending correctly the info, and the Processing app is receiving it correctly too, but when I try to save the data into an array, it doesn’t update the values. T…

---

## [Creating a controller with conductive paint and using in Processing](https://discourse.processing.org/t/creating-a-controller-with-conductive-paint-and-using-in-processing/16679)

<div class="topic-metadata">

**Author:** [@marianne91](https://discourse.processing.org/u/marianne91)\
**Replies:** 10\
**Last updated:** [January 8, 2020, 1:47pm UTC](https://discourse.processing.org/t/creating-a-controller-with-conductive-paint-and-using-in-processing/16679 "2020-01-08T13:47:06Z")

</div>

Hi there, I’m looking to make a project in which activity on a screen is generated by someone stepping on a painted surface (with bare conductive paint - https://www.bareconductive.com/). This action of stepping on the…

---

## [How can I convert voice data to a .wav file?](https://discourse.processing.org/t/how-can-i-convert-voice-data-to-a-wav-file/16893)

<div class="topic-metadata">

**Author:** [@GWAK](https://discourse.processing.org/u/GWAK)\
**Replies:** 2\
**Last updated:** [January 7, 2020, 2:36am UTC](https://discourse.processing.org/t/how-can-i-convert-voice-data-to-a-wav-file/16893 "2020-01-07T02:36:26Z")

</div>

how can I convert voice data to a .wav file? Hello. nice to meet you. I am using Arduino to get the voice value from the microphone to the ADC. I send the ADC value to a PC and want save it as a .wav file. In other…

---

## [Sound and text error in Processing](https://discourse.processing.org/t/sound-and-text-error-in-processing/16860)

<div class="topic-metadata">

**Author:** [@e.p](https://discourse.processing.org/u/e.p)\
**Replies:** 5\
**Last updated:** [January 6, 2020, 7:21pm UTC](https://discourse.processing.org/t/sound-and-text-error-in-processing/16860 "2020-01-06T19:21:40Z")

</div>

Hello everyone :smiley: I have a problem with this drummachine. I can not add another row of sound that is from my disktop and not from Minim. The 4. row just plays the previous soundpiece? What can I do to change it? …

---

## [Running sketch files to LED matrix from MacBook Pro](https://discourse.processing.org/t/running-sketch-files-to-led-matrix-from-macbook-pro/13427)

<div class="topic-metadata">

**Author:** [@blackdiam\_echo](https://discourse.processing.org/u/blackdiam_echo)\
**Replies:** 6\
**Last updated:** [August 20, 2019, 9:37am UTC](https://discourse.processing.org/t/running-sketch-files-to-led-matrix-from-macbook-pro/13427 "2019-08-20T09:37:42Z")

</div>

Hello all, this is my first post here and I am so glad to have discovered Processing and this community. At the same time please excuse my ignorance. I am looking to run sketch files onto a LED matrix. I can see plenty…

---

## [Unexpected Character Movement](https://discourse.processing.org/t/unexpected-character-movement/16716)

<div class="topic-metadata">

**Author:** [@fredstout](https://discourse.processing.org/u/fredstout)\
**Replies:** 9\
**Last updated:** [January 1, 2020, 3:54pm UTC](https://discourse.processing.org/t/unexpected-character-movement/16716 "2020-01-01T15:54:44Z")

</div>

I am developing a sketch to graphically display GPS data coming from an Arduino. The sketch paints the background and “gauge” bezel and then calls various functions to fill in the face with appropriate data, . The comp…

---

## [How can I run a video on arduino by using processing?](https://discourse.processing.org/t/how-can-i-run-a-video-on-arduino-by-using-processing/16771)

<div class="topic-metadata">

**Author:** [@muhammad\_bilal125](https://discourse.processing.org/u/muhammad_bilal125)\
**Replies:** 0\
**Last updated:** [January 1, 2020, 7:25am UTC](https://discourse.processing.org/t/how-can-i-run-a-video-on-arduino-by-using-processing/16771 "2020-01-01T07:25:24Z")

</div>

Actually i want to run a video on arduino through processing. Can anyone guide me how i can do it? Kindly immediately need help…

---

## [Unpacking serial data from arduino](https://discourse.processing.org/t/unpacking-serial-data-from-arduino/16662)

<div class="topic-metadata">

**Author:** [@urthlight](https://discourse.processing.org/u/urthlight)\
**Replies:** 12\
**Last updated:** [December 29, 2019, 11:07pm UTC](https://discourse.processing.org/t/unpacking-serial-data-from-arduino/16662 "2019-12-29T23:07:07Z")

</div>

Can someone help me understand what is going on here. I am receiving serial data in the format “angle,sonar distance,ir distance.”. My code works with the first 2 variables. I am trying to add the third. I do not unders…

---

## [Code for TouchOSC and Arduino doesn't work](https://discourse.processing.org/t/code-for-touchosc-and-arduino-doesnt-work/16627)

<div class="topic-metadata">

**Author:** [@MikeAelbrecht](https://discourse.processing.org/u/MikeAelbrecht)\
**Replies:** 1\
**Last updated:** [December 25, 2019, 11:41am UTC](https://discourse.processing.org/t/code-for-touchosc-and-arduino-doesnt-work/16627 "2019-12-25T11:41:10Z")

</div>

This is my Processing code: import oscP5.; // Load OSC P5 library import netP5.; // Load net P5 library import processing.serial.\*; // Load serial library Serial arduinoPort; // Set arduin…

---

## [Serial write fails on the first write](https://discourse.processing.org/t/serial-write-fails-on-the-first-write/16564)

<div class="topic-metadata">

**Author:** [@pandl](https://discourse.processing.org/u/pandl)\
**Replies:** 4\
**Last updated:** [December 24, 2019, 10:54pm UTC](https://discourse.processing.org/t/serial-write-fails-on-the-first-write/16564 "2019-12-24T22:54:15Z")

</div>

Thank you for reading this. I’ve spent most of the day trying to discover why the serial write function will not send the correct data the first time. If I send the same block of data twice then the correct data is recei…

---

## [Arduino to Processing](https://discourse.processing.org/t/arduino-to-processing/16451)

<div class="topic-metadata">

**Author:** [@Cbeni](https://discourse.processing.org/u/Cbeni)\
**Replies:** 1\
**Last updated:** [December 16, 2019, 10:51pm UTC](https://discourse.processing.org/t/arduino-to-processing/16451 "2019-12-16T22:51:01Z")

</div>

Hello! I am trying to send info from arduino to processing but my code is not working, it worked before! =\[ Does the board need to be plugged in to work? Can someone please explain whats wrong? Processing Code impor…

---

## [Giving wrong value while reading data from serial port](https://discourse.processing.org/t/giving-wrong-value-while-reading-data-from-serial-port/16447)

<div class="topic-metadata">

**Author:** [@iamgsshetty](https://discourse.processing.org/u/iamgsshetty)\
**Replies:** 3\
**Last updated:** [December 16, 2019, 1:14pm UTC](https://discourse.processing.org/t/giving-wrong-value-while-reading-data-from-serial-port/16447 "2019-12-16T13:14:48Z")

</div>

processing code:- import processing.serial.\*; Serial myport; float v1,v2,a,cda=0.0,how=0.0,water=0.0; void setup() { myport = new Serial(this, Serial.list()\[0\], 9600); } void draw() { if(0\<myport.available()) …

---

## [Multiple arduino inputs](https://discourse.processing.org/t/multiple-arduino-inputs/16275)

<div class="topic-metadata">

**Author:** [@neneeangulo](https://discourse.processing.org/u/neneeangulo)\
**Replies:** 6\
**Last updated:** [December 13, 2019, 1:52am UTC](https://discourse.processing.org/t/multiple-arduino-inputs/16275 "2019-12-13T01:52:44Z")

</div>

Hi! I am trying to use flex sensors to change the position of a drawing in processing. I got one of the flex sensors to work and move the drawing, but it moves all the parts of the drawing that should be controlled by d…

---

## [Video forwarding with Processing - request](https://discourse.processing.org/t/video-forwarding-with-processing-request/16326)

<div class="topic-metadata">

**Author:** [@galgal12345](https://discourse.processing.org/u/galgal12345)\
**Replies:** 2\
**Last updated:** [December 12, 2019, 2:28am UTC](https://discourse.processing.org/t/video-forwarding-with-processing-request/16326 "2019-12-12T02:28:27Z")

</div>

Hi guys, Im new to Arduino+Processing and I have a project for school. can anyone help me with coding this task- Im using an infrared sensor with this code on arduino (attached) and I would like to ‘forward’ a playin…

---

## [Linear Potentiometer](https://discourse.processing.org/t/linear-potentiometer/16270)

<div class="topic-metadata">

**Author:** [@ozman](https://discourse.processing.org/u/ozman)\
**Replies:** 5\
**Last updated:** [December 10, 2019, 4:41am UTC](https://discourse.processing.org/t/linear-potentiometer/16270 "2019-12-10T04:41:54Z")

</div>

Hi, i am trying to make a game using a single linear potentiometer where you can draw line Up, Down, Left and Right. So far i am able to move in every direction by pressing ‘H’ to change the axis direction to up and do…

[Previous page](https://discourse.processing.org/c/processing/processing-electronics/25.md?page=14)

[Next page](https://discourse.processing.org/c/processing/processing-electronics/25.md?page=16)
