hi
i found sample code regarding plx-daq
but dont know how combine code analog reading on a0 pin of arduino.
how can add analog reading a0 address code import data arduino ?
this basic code of plx-daq
int x = 0;
int row = 0;
void setup() {
serial.begin(128000); // opens serial port, sets data rate 9600 bps
serial.println("cleardata");
serial.println("label,time,x,sin(x)");
}
void loop() {
serial.print("data,time,"); serial.print(x); serial.print(","); serial.println(sin(x*pi/180));
row++;
x++;
if (row > 360)
{
row=0;
serial.println("row,set,2");
}
delay(100);
}
i found sample code regarding plx-daq
but dont know how combine code analog reading on a0 pin of arduino.
how can add analog reading a0 address code import data arduino ?
this basic code of plx-daq
int x = 0;
int row = 0;
void setup() {
serial.begin(128000); // opens serial port, sets data rate 9600 bps
serial.println("cleardata");
serial.println("label,time,x,sin(x)");
}
void loop() {
serial.print("data,time,"); serial.print(x); serial.print(","); serial.println(sin(x*pi/180));
row++;
x++;
if (row > 360)
{
row=0;
serial.println("row,set,2");
}
delay(100);
}
i question timing , baud rate in code post but, if works, works. assume graphs 2 values, x , sine thereof, against time.
the example analoginoutserial in ide might want. might easier grasp if, instead of trying integrate analogue reading plx example, use plx methodology print data analogue programme.
the example analoginoutserial in ide might want. might easier grasp if, instead of trying integrate analogue reading plx example, use plx methodology print data analogue programme.
Arduino Forum > Using Arduino > Interfacing w/ Software on the Computer > reading analog input + PLX-DAQ
arduino
Comments
Post a Comment