|
O‘rnatilgan tizimlari fanidan 3-amaliy ish mavzu: 8x8 yorug‘lik diodi, pezonurlatgich va 74NS595 suruvchi registr xususiyatlarini o‘rganish
|
Sana | 15.05.2024 | Hajmi | 331,57 Kb. | | #235174 |
Bog'liq ornatilgan3
O‘ZBEKISTON RESPUBLIKASI
RAQAMLI TEXNOLOGIYALAR VAZIRLIGI
MUHAMMAD AL-XORAZMIY NOMIDAGI
TOSHKENT AXBOROT TEXNOLOGIYALARI UNIVERSITETI
Kompyuter injiniringi fakulteti
Sun’iy intellekt kafedrasi
O‘rnatilgan tizimlari fanidan
3-AMALIY ISH
Mavzu: 8x8 yorug‘lik diodi, pezonurlatgich va 74NS595 suruvchi registr xususiyatlarini o‘rganish.
Bajardi: 411-21 guruh talabasi
Murodillayev Abdulatif
Tekshirdi: Azimova Umida
TOSHKENT – 2024
12
74NS595 suruvchi registr mikrosxemasida 1 razryadli 7 segmetli indikatorda sonlarni o
‘sish va kamayish tartibida chiqarish
12
Dastur kodi
const int dataPin = 12; /* DS */
const int clockPin = 10; /* SHCP */
const int latchPin = 11; /* STCP */
int son[10]={ B10111111, //0
B10000110, //1
B01011011, //2
B11001111, //3
B11100110, //4
B11101101, //5
B11111101, //6
B10000111, //7
B11111111, //8
B11101111};//9
void setup() {
pinMode(dataPin, OUTPUT);
pinMode(clockPin, OUTPUT);
pinMode(latchPin, OUTPUT);
Serial.begin(9600);
}
void loop() {
for (int i=0; i<10; i++){
digitalWrite(latchPin, LOW);
Serial.println(i);
shiftOut(dataPin, clockPin, MSBFIRST, son[i]);
digitalWrite(latchPin, HIGH);
delay(1000);
}
for (int i=9; i>=0; i--){
digitalWrite(latchPin, LOW);
Serial.println(i);
shiftOut(dataPin, clockPin, MSBFIRST, son[i]);
digitalWrite(latchPin, HIGH);
delay(1000);
}
}
Dastur natijasi
|
|
Bosh sahifa
Aloqalar
Bosh sahifa
O‘rnatilgan tizimlari fanidan 3-amaliy ish mavzu: 8x8 yorug‘lik diodi, pezonurlatgich va 74NS595 suruvchi registr xususiyatlarini o‘rganish
|