DIY osciloscope and Logic analyser

On the quest to make my own oscilloscope and logic analyser using KST Planning to make a gui that will read the serial port and log the data to file that will be read by the awesome KST Main issue is bandwidth.but an oscilloscope and logic analyser for a couple of hundred it will work just fine

This a test with arduino and a micro-mouse sensor IMG-20130207-00266

This a work in progress. Will post any updates here soon..

Finally found this amazing project with some neat features called  Lxardoscope

Its a dual channel oscilloscope, the hardware consists of a mega 8 and the data is sent to computer via UART @115200.

The software has some very nice features, not found in most diy oscilloscope.

Only down side there is no windows port, also the data plotted can be considered soft real time, because the data is collected every 300ms, its great for low bandwidth applications

IMG-20130426-00318

Another method of getting more channels I used a software called KST, available for windows and linux, Doing this is a long process, I wrote a small program for arduino, that get raw values of all the sensors, the data is sent to PC via UART in csv format, the terminal program I use is GTK-Term , then log the data to a file, also open that file in KST, and the KST starts to plot the data.

Here is an example I recorded with two channels

Screenshot from 2013-06-13 14:45:43

Here is the arduino code I wrote in version 22:

int analog0;
int analog1;
int analog2;
int analog3;
int analog4;
int analog5;
int analog6;

unsigned long time;
byte serialByte;
float i;
//////////////

////////////////
void setup() {

  Serial.begin(115200);
  Serial.println("Press 'C' to Start logging,and 'F' to stop");
}

void loop()
{

  while (Serial.available()>0){  
    serialByte=Serial.read();
    if (serialByte=='C'){      
      while(1){
        analog0=analogRead(0);
        analog1=analogRead(1);
        analog2=analogRead(2);
        analog3=analogRead(3);
        analog4=analogRead(4);
        analog4=analogRead(5);
        analog4=analogRead(6);

        Serial.print(analog0,DEC);
        Serial.print(',',BYTE);
        Serial.print(analog1,DEC);
        Serial.print(',',BYTE);
        Serial.print(analog2,DEC);
        Serial.print(',',BYTE);
        Serial.print(analog3,DEC);
        Serial.print(',',BYTE);
        Serial.println(analog4,DEC);
        Serial.print(',',BYTE);
        Serial.print(analog5,DEC);
        Serial.print(',',BYTE);
        Serial.print(analog6,DEC);

        if (Serial.available()>0){
          serialByte=Serial.read();
          if (serialByte=='F')  {
          break;
          }    
        }
      }
    }
  }
}