Ask Question

Name:
Title:
Your Question:

Answer Question

Name:
Your Answer:
Latest Saved Source Codes!

Source Code 12191 - armsrong number, Language: C/C++
Source Code 12190 - Hell world!, Language: C/C++
Source Code 12189 - Hell world!, Language: C/C++
Source Code 12188 - a.c, Language: C/C++
Source Code 12187 - teste, Language: C/C++
Source Code 12186 - teste, Language: C/C++
Source Code 12185 - teste, Language: C/C++
Source Code 12184 - a, Language: C/C++
Source Code 12183 - lol, Language: C/C++
Source Code 12182 - OTPHomework.java, Language: JAVA
Source Code 12181 - baba, Language: C/C++
Source Code 12180 - a, Language: C/C++
Source Code 12179 - a, Language: C/C++
Source Code 12178 - Hello World, Language: JAVA
Source Code 12177 - sad, Language: C/C++
Source Code 12176 - teste, Language: C/C++
Source Code 12175 - helo, Language: JAVA
Source Code 12174 - helloworld.java, Language: JAVA
Source Code 12173 - hello, Language: JAVA
Source Code 12172 - 1, Language: C/C++
Source Code 12171 - test, Language: C/C++
Source Code 12170 - qwe, Language: C/C++
Source Code 12169 - HelloWorld.java, Language: JAVA
Source Code 12168 - FCFS, Language: JAVA
Source Code 12167 - FCFS.java, Language: JAVA
Source Code 12166 - FCFS.java, Language: JAVA
Source Code 12165 - FirstComeFirstServed.java, Language: JAVA
Source Code 12164 - fcfs, Language: C/C++
Source Code 12163 - asd, Language: C/C++
Source Code 12162 - programe.c, Language: C/C++
Source Code 12161 - HOW, Language: JAVA
Source Code 12160 - rettangolo.pas, Language: PASCAL
Source Code 12159 - TEST11111, Language: BASIC
Source Code 12158 - RETTANGOLO, Language: PASCAL
Source Code 12157 - ag, Language: C/C++
Source Code 12156 - hello woed, Language: JAVA
Source Code 12155 - 1, Language: C/C++
Source Code 12154 - sds, Language: C/C++
Source Code 12153 - diff, Language: C/C++
Source Code 12152 - diff, Language: C/C++
Source Code 12151 - programa idade, Language: C/C++
Source Code 12150 - c sample, Language: C/C++
Source Code 12149 - asinmnt, Language: C/C++
Source Code 12148 - asinmnt, Language: C/C++
Source Code 12147 - programação 1, Language: C/C++
Source Code 12146 - s, Language: C/C++
Source Code 12145 - ивапв, Language: C/C++
Source Code 12144 - a, Language: C/C++
Source Code 12143 - addition of two no#s, Language: C/C++
Source Code 12142 - sd, Language: C/C++
Source Code 12141 - calculation, Language: C/C++
Source Code 12140 - calculation, Language: C/C++
Source Code 12139 - java test1, Language: JAVA
Source Code 12138 - java test1, Language: JAVA
Source Code 12137 - char char, Language: C/C++
Source Code 12136 - sad, Language: C/C++
Source Code 12135 - sad, Language: C/C++
Source Code 12134 - aa, Language: C/C++
Source Code 12133 - aa, Language: C/C++
Source Code 12132 - ggfh, Language: JAVA
Source Code 12131 - ss, Language: C/C++
Source Code 12130 - ss, Language: C/C++
Source Code 12129 - asd, Language: C/C++
Source Code 12128 - asd, Language: C/C++
Source Code 12127 - gf, Language: C/C++
Source Code 12126 - area, Language: FORTRAN
Source Code 12125 - area, Language: FORTRAN
Source Code 12124 - test, Language: C/C++
Source Code 12123 - sum of two equal digit number, Language: C/C++
Source Code 12122 - aw, Language: C/C++
Source Code 12121 - sum of two equal digit number, Language: C/C++
Source Code 12120 - sum of two equal digit number, Language: C/C++
Source Code 12119 - nn, Language: C/C++
Source Code 12118 - rsa, Language: C/C++
Source Code 12117 - x, Language: C/C++
Source Code 12116 - a, Language: C/C++
Source Code 12115 - Stack.java, Language: JAVA
Source Code 12114 - we, Language: FORTRAN
Source Code 12113 - Blip, Language: JAVA
Source Code 12112 - winr, Language: C/C++
Source Code 12111 - winr, Language: C/C++
Source Code 12110 - winr, Language: C/C++
Source Code 12109 - switchp, Language: C/C++
Source Code 12108 - PyramidNumber.java, Language: JAVA
Source Code 12107 - amstrong number, Language: C/C++
Source Code 12106 - amstrong number, Language: C/C++
Source Code 12105 - hello, Language: JAVA
Source Code 12104 - aa, Language: C/C++
Source Code 12103 - h, Language: JAVA
Source Code 12102 - movie, Language: C/C++
Source Code 12101 - HOTEL, Language: C/C++
Source Code 12100 - .txt, Language: C/C++
Source Code 12099 - sick, Language: PASCAL
Source Code 12098 - struktura, Language: C/C++
Source Code 12097 - me, Language: BASIC
Source Code 12096 - blub, Language: PASCAL
Source Code 12095 - progran by hiuri, Language: C/C++
Source Code 12094 - progran by hiuri, Language: C/C++
Source Code 12093 - progran by hiuri, Language: C/C++
Source Code 12092 - мама мыла раму, Language: PASCAL
Source Code 12091 - ADDITION TRIAL, Language: FORTRAN
Source Code 12090 - hello, Language: C/C++
Source Code 12089 - compile, Language: FORTRAN
Source Code 12088 - g.c, Language: C/C++
Source Code 12087 - Game.java, Language: JAVA
Source Code 12086 - jj]\, Language: C/C++
Source Code 12085 - promedio, Language: PASCAL
Source Code 12084 - 123, Language: C/C++
Source Code 12083 - zs, Language: C/C++
Source Code 12082 - s, Language: C/C++
Source Code 12081 - s, Language: C/C++
Source Code 12080 - s, Language: C/C++
Source Code 12079 - temp.java, Language: JAVA
Source Code 12078 - asas, Language: PASCAL
Source Code 12077 - asas, Language: PASCAL
Source Code 12076 - roman to decimal, Language: C/C++
Source Code 12075 - rLdz9DzQ.java, Language: JAVA
Source Code 12074 - sum, Language: C/C++
Source Code 12073 - sum, Language: C/C++
Source Code 12072 - ex, Language: C/C++
Source Code 12071 - hai, Language: C/C++
Source Code 12070 - main.cpp, Language: C/C++
Source Code 12069 - differentiation, Language: FORTRAN
Source Code 12068 - main.cpp, Language: C/C++
Source Code 12067 - kp, Language: C/C++
Source Code 12066 - if statement, Language: C/C++
Source Code 12065 - mn, Language: C/C++
Source Code 12064 - mo, Language: C/C++
Source Code 12063 - mo, Language: C/C++
Source Code 12062 - ASD, Language: C/C++
Source Code 12061 - watson delaunay, Language: FORTRAN
Source Code 12060 - first.c, Language: C/C++
Source Code 12059 - first.c, Language: C/C++
Source Code 12058 - c, Language: C/C++
Source Code 12057 - kl, Language: C/C++
Source Code 12056 - k, Language: C/C++
Source Code 12055 - pascal, Language: PASCAL
Source Code 12054 - hello, Language: JAVA
Source Code 12053 - Array deletion, Language: C/C++
Source Code 12052 - empresa, Language: PASCAL
Source Code 12051 - HOLA, Language: C/C++
Source Code 12050 - sad, Language: C/C++
Source Code 12049 - sad, Language: C/C++
Source Code 12048 - testing, Language: C/C++
Source Code 12047 - testing, Language: C/C++
Source Code 12046 - 90army, Language: PASCAL
Source Code 12045 - football, Language: PASCAL
Source Code 12044 - test, Language: C/C++
Source Code 12043 - calc, Language: C/C++
Source Code 12042 - kl, Language: C/C++
Source Code 12041 - kl, Language: C/C++
Source Code 12040 - Hello World, Language: C/C++
Source Code 12039 - rotate, Language: JAVA
Source Code 12038 - ABC, Language: C/C++
Source Code 12037 - yu, Language: C/C++
Source Code 12036 - #include <stdio.h>, Language: C/C++
Source Code 12035 - AA, Language: BASIC
Source Code 12034 - d, Language: C/C++
Source Code 12033 - d, Language: C/C++
Source Code 12032 - a, Language: C/C++
Source Code 12031 - a, Language: C/C++
Source Code 12030 - hai, Language: C/C++
Source Code 12029 - hai, Language: C/C++
Source Code 12028 - yfvyujf, Language: BASIC
Source Code 12027 - AddYear.java, Language: JAVA
Source Code 12026 - a thing, Language: JAVA
Source Code 12025 - a, Language: C/C++
Source Code 12024 - d, Language: C/C++
Source Code 12023 - sample Prgorm, Language: C/C++
Source Code 12022 - jvfd, Language: C/C++
Source Code 12021 - hq, Language: C/C++
Source Code 12020 - main, Language: C/C++
Source Code 12019 - ййй, Language: C/C++
Source Code 12018 - ййй, Language: C/C++
Source Code 12017 - dd, Language: C/C++
Source Code 12016 - sss, Language: C/C++
Source Code 12015 - kk, Language: C/C++
Source Code 12014 - burn, Language: C/C++
Source Code 12013 - burn, Language: C/C++
Source Code 12012 - / WINAVR GCC // ATmega8 // clock: internal 1Mhz #include <avr/io.h> #include <avr/interrupt.h> #include <avr/signal.h> #include <avr/delay.h> #include <avr/eeprom.h> #include "3310LCD_function.c" #define uchar uint8_t #define uint uint16_t #define SLA_W 0b11000000 #define SLA_R 0b11000001 uchar senddata[5]; uchar readdata[5]; uchar search = 0; uchar search_up = 0; //------------------------------- // ?? void delay_ms(uint ms) { uint i; for(i=0;i<ms;i++) _delay_loop_2(250); } void set5767(void) { uchar i = 0; TWCR = (1<<TWINT)|(1<<TWSTA)|(1<<TWEN); // SEND START SIGNAL while (!(TWCR & (1<<TWINT))); // WAIT FOR START SIG //if ((TWSR & 0xF8) != START) ERROR(); TWDR = SLA_W; // send address TWCR = (1<<TWINT) | (1<<TWEN); while (!(TWCR & (1<<TWINT))); //if ((TWSR & 0xF8) !=MT_SLA_ACK) ERROR(); for ( i = 0; i < 5; i++ ) { TWDR = senddata[i]; TWCR = (1<<TWINT) | (1<<TWEN); // send data while (!(TWCR & (1<<TWINT))); // if ((TWSR & 0xF8) != MT_DATA_ACK) ERROR(); } TWCR = (1<<TWINT)|(1<<TWEN)|(1<<TWSTO); //SEND STOP SIGNAL //LCD_write_english_string(60,3,"sOK"); } void read5767(void) { uchar i = 0; TWCR = (1<<TWINT)|(1<<TWSTA)|(1<<TWEN); // SEND START SIGNAL while (!(TWCR & (1<<TWINT))); // WAIT FOR START SIG //if ((TWSR & 0xF8) != START) ERROR(); TWDR = SLA_R; // send address TWCR = (1<<TWINT) | (1<<TWEN); while (!(TWCR & (1<<TWINT))); //if ((TWSR & 0xF8) !=MT_SLA_ACK) ERROR(); //TWCR = (1<<TWINT) | (1<<TWEN); for ( i = 0; i < 5; i++ ) { TWCR = (1<<TWINT) | (1<<TWEN); // read data while (!(TWCR & (1<<TWINT))); readdata[i] = TWDR ; // if ((TWSR & 0xF8) != MT_DATA_ACK) ERROR(); } TWCR = (1<<TWINT)|(1<<TWEN)|(1<<TWSTO); //SEND STOP SIGNAL //LCD_write_english_string(10,3,"rOK"); } void show_frequency(void) { uint32_t nPLL =0; //Dec uint32_t frequency = 0; //Khz uchar display_bit[5]; uchar tbTmp1=readdata[1]; uchar tbTmp2=readdata[0]; tbTmp2&=0x3f; nPLL=tbTmp2*256+tbTmp1; // calculate searched station frequency if(senddata[2]&0x10) frequency =(unsigned long)(nPLL*82/10-225); else frequency =(unsigned long)(nPLL*82/10+225); display_bit[0] = frequency / 100000 ; if ( display_bit[0] == 0 ) display_bit[0] = 0x20; else display_bit[0] += 0x30; display_bit[1] = (frequency / 10000)%10 +0x30; display_bit[2] = (frequency / 1000)%10 +0x30; display_bit[3] = (frequency / 100)%10 +0x30; display_bit[4] = (frequency / 10)%10 +0x30; LCD_write_english_string(0,2," " ); LCD_write_char(display_bit[0]); LCD_write_char(display_bit[1]); LCD_write_char(display_bit[2]); LCD_write_english_string(25,2,"." ); LCD_write_char(display_bit[3]); LCD_write_char(display_bit[4]); LCD_write_english_string(43,2," MHz" ); } void show_rx_power(void) { uchar temp; temp = (readdata[3]>>4); LCD_write_english_string(60,0," "); LCD_write_char((temp/10)%10 + 0x30 ); LCD_write_char(temp%10 + 0x30 ); } void init(void) { DDRB = 0XFF; PORTB = 0XFF; DDRD = 0B11100000; PORTD = 0XFF; DDRC = 0B00000000; PORTC = 0Xff; // IO init delay_nms(100); //TWI TWBR = 12; TWCR = (1<<TWEN); //SEND STOP SIGNAL OSCCAL=0x9d; // 8M???????? //??MCU?I/O? DDRB |= LCD_RST | LCD_DC | LCD_CE | SPI_MOSI | SPI_CLK; SPSR |= (1<<SPI2X); // ??SPI???? SPCR |= (1<<SPE)|(1<<MSTR); // ??SPI??,????,4M?? LCD_init(); //????? } ////////////////////////////////////////////////////////////////// int main(void) { init(); senddata[0] = 0b01101111; //load 100MHz pll senddata[1] = 0b10010011; // away's low side injection senddata[2] = 0b00100000; senddata[3] = 0b10010000; senddata[4] = 0b00000000; readdata[0] = senddata[0]; readdata[1] = senddata[1]; LCD_write_english_string(0,0,"FM STEREO" ); //LCD_write_english_string(0,5," stereo" ); LCD_write_english_string(0,2," 99.1Mhz" ); show_frequency(); LCD_write_inverse_string(0,5," UP "); LCD_write_inverse_string(48,5," DOWN "); while(1) { if ( bit_is_clear( PIND,3)) { delay_nms(20); if ( bit_is_clear( PIND,3)) { loop_until_bit_is_set(PIND, 3); LCD_write_english_string(0,4,"KEY1 press" ); senddata[2] &= 0x7f; // set search down set5767(); LCD_write_english_string(0,4,"searching down" ); search_up = 0; search = 1; } } if ( bit_is_clear( PIND,2)) { delay_nms(20); if ( bit_is_clear( PIND,2)) { loop_until_bit_is_set(PIND, 2); LCD_write_english_string(0,4,"KEY2 press" ); senddata[2] |= 0x80; // set search up set5767(); LCD_write_english_string(0,4,"searching up "); search_up = 1; search = 1; } } if ( search ) { read5767(); if ( readdata[0] & 0x40 ) //reach band end { if ( search_up ) { senddata[0] = 0b01101001; // load 88Mhz pll senddata[1] = 0b11011010; set5767(); } else { senddata[0] = 0b01110011; // load 108Mhz pll senddata[1] = 0b01100100; set5767(); } } if ( readdata[0] & 0x80) //has been found a station { show_frequency(); show_rx_power(); senddata[0] = ((readdata[0] & 0x3f) |0x40); senddata[1] = readdata[1]; //record the pll search = 0; } } } }, Language: C/C++
Source Code 12011 - faruq , Language: JAVA
Source Code 12010 - nice thing, Language: C/C++
Source Code 12009 - nice thing, Language: C/C++
Source Code 12008 - cpp, Language: C/C++
Source Code 12007 - cpp, Language: C/C++
Source Code 12006 - s, Language: C/C++
Source Code 12005 - encriptar, Language: C/C++
Source Code 12004 - 1, Language: JAVA
Source Code 12003 - jogo da velha, Language: C/C++
Source Code 12002 - error in iostream.h, Language: C/C++
Source Code 12001 - hello, Language: C/C++
Source Code 12000 - hello, Language: C/C++
Source Code 11999 - hello, Language: C/C++
Source Code 11998 - test, Language: C/C++
Source Code 11997 - 90, Language: C/C++
Source Code 11996 - nlkl, Language: PASCAL
Source Code 11995 - ddos, Language: C/C++
Source Code 11994 - ok, Language: PASCAL
Source Code 11993 - a, Language: C/C++
Source Code 11992 - sample.c, Language: C/C++