![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Jul 2008
Posts: 1
Rep Power: 0
![]() |
I/O Interfacing 8255 PPI (need help)
How to write a program the detect the input switches(SW2-0 & SW2-1) Value?
SW2-1(OFF) & SW2-0(OFF), all the LED'S light are blinking . What are the codes to fill in. Thanks for the help ![]() #include "stdafx.h" #include "Test8255Dll.h" #include "Test8255DllDlg.h" #include "decdio.h" #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE static char THIS_FILE[] = __FILE__; #endif void CTest8255DllDlg::test8255loopback() { static int loop = 0; unsigned char z1 = 0; CString str; if (!m_hDevice) return; // *****Type your code here****** // *********End your code here ********* str.Format("Loop: %3d Input Switch:%02X",loop + 1, z1); m_display8255.SetWindowText(str); loop++; if(loop > 1000) loop = 0; } |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| I/O proccessing | Freaky Chris | Python | 8 | Mar 24th, 2008 10:42 AM |
| Interfacing With Hardware | pal | C++ | 5 | Sep 14th, 2007 10:01 AM |
| USB Interfacing | samra | Assembly | 2 | Mar 23rd, 2005 1:15 AM |
| Interfacing with a Keyboard | brkstf | Assembly | 7 | Mar 21st, 2005 3:48 PM |
| Problem with VB interfacing to C++ | uman | C++ | 0 | Feb 24th, 2005 8:07 PM |