top of page
  • Writer's pictureAtchareeya Jattuporn

Lab6 : Serial Communication - Blooming Piano


This week, I combined my piano from last week with my last ICM sketch and elevated it to be a blooming piano. Every time when the key is pressed, flower will bloom onscreen.


Sketch Part

I improve my sketch by using array function. I was really satisfied with this. Here is a sketch before I combined it with Arduino.

Let's try by clicking anywhere !

https://editor.p5js.org/Atchareeya_J/sketches/S6QOfubEH


Serial Communication with Arduino

I try to use digital input from Arduino to communicate with P5js. I found that I don't understand the logic of serial communication that much. Fortunately, after searching for the solution, I found one sketch that explained it very well. (reference below)


reference for digital input serial communication idea:

https://gist.github.com/extrasleepy/c2807755b6276da6bdac

sketch :

https://editor.p5js.org/Atchareeya_J/sketches/oauy2etD8


Testing


Finally I did it !



29 views

Recent Posts

See All
bottom of page