mirror of
https://github.com/processing/processing4.git
synced 2026-02-14 02:45:36 +01:00
14 lines
231 B
Plaintext
14 lines
231 B
Plaintext
import processing.io.*;
|
|
MCP3001 adc;
|
|
|
|
// see setup.png in the sketch folder for wiring details
|
|
|
|
void setup() {
|
|
//printArray(SPI.list());
|
|
adc = new MCP3001(SPI.list()[0]);
|
|
}
|
|
|
|
void draw() {
|
|
background(adc.getAnalog() * 255);
|
|
}
|