Jump to content



Photo
* * * - - 1 votes

CASIO scope v. 1.0

programming zx syncroscope

  • Please log in to reply
No replies to this topic

#1 marcobiaggini

marcobiaggini

    Newbie

  • Members
  • Pip
  • 5 posts
  • Gender:Male
  • Location:ITALY
  • Interests:Marine engines, Programming on handel devices , Blackberry devices

  • Calculators:
    PB700
    PB2000C
    Z1- GR
    BLACKBERRY PLAYBOOK
    BLACKBERRY PASSPORT

Posted 25 November 2016 - 05:27 PM

Good morning, If you have an analogic syncroscope often you need to check your risetime showed on crt screen, now you can program your casio to help you about found the right measure sound.

 

16:50 - MarcoBiaggini:

C program CASIO scope V.1.0

Float risetime(x,y){
    Float tr;
    tr=sqrt((x*x)+(y*y));
    Return tr;
}

Float bandw(z) {
    Float bw;
    bw=350/z;
    Return bw;
}

Void square() {
    Line(12,5,38,5);line(38,5,38,28);
    line(38,25,12,25);line(12,25,12,5);
    Return
}

Main() {
    Int i,a;
    Float bw1,bw2,bws,tr1,tr2,trs;
    Clrscr();
    fflush(stdin);
    printf("¥a");
    square();
    Line(18,27,18,25);    line(25,24,25,25);    line(32,24,32,25);
    line(12,15,20,15);    line(20,15,20,10);    line(20,10,30,10);
    line(30,10,30,20);    line(30,20,33,20);    line(33,20,33,15);
    line(33,15,38,15);
    Gotoxy(20,2);    printf("loading");
    Gotoxy(12,0);    printf("CASIO scope v. 1.0");
    Line(72,24,170,24);    line(170,24,170,30);    line(170,30,72,30);
    Line(72,30,72,24);
    For (i=72;i<=170;i++) 
{ line(i,24,i,30);  }
    Gotoxy(20,2);
    printf("¥aready¥a");
    Menu: Clrscr();fflush(stdin);
    Gotoxy(0,0);
    printf("MENU");
    Gotoxy(0,2);  printf("- RISETIME ");
    Gotoxy(0,3);  printf("- BANDWIDTH ");
    Gotoxy(29,3); printf("?");
    scanf("%d",&a);
    Switch(a) {
        Case "r":
            goto time ;
            Break;
        Case "b":
            goto band;
            Break;
        Deafault:
            printf("ERROR");
            goto menu; } 
Time:
    Clrscr();
    fflush(stdin);
    square();
    Gotoxy(8,0);
    printf("RISETIME CALCULATION");
    Line(12,23,22,10);   line(22,10,28,20);
    line(28,20,34,8);    line(34,8,31,10);
    line(34,8,35,11);    Gotoxy(13,2);  printf("SCOPE BAND[Mhz]?");
    Scanf("%f",&bw1);
    Gotoxy(12,2); printf("SOUND BAND[Mhz]?");
    Scanf("%f",&bw2);
    Tr1=350/bw1;tr2=350/bw2;
    trs=risetime(tr1,tr2);
    Gotoxy(12,2); printf("¥aRISETIME= %f.2 [ns]",trs);
    Fflush(stdin); getchar();  goto menu;
    Band: Gotoxy(8.0);
    printf("BANDWIDTH");
    square; Line(20,20,18,20);
    line(18,20,18,7);  line(18,7,20,7);
    line(32,7,30,7);   line(32,7,32,20);
    line(32,20,30,20);
    Gotoxy(4,2);  printf("~");
    Gotoxy(10,2); printf("SCREEN TIME [ns]?");
    Scanf("%f",&trs);  Bws=bandw(trs);
    Gotoxy(9,2); printf("¥aBANDWIDTH= %.2f [Mhz]",bws);
    Fflush(stdin);
    getchar();
    goto menu;
}  

IMG_20161120_201911.jpg

 


Edited by marcobiaggini, 25 November 2016 - 10:16 PM.
Changed formatting




Also tagged with one or more of these keywords: programming, zx, syncroscope

1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users