mirror of
https://github.com/byteworksinc/ORCA-C.git
synced 2024-12-22 07:30:54 +00:00
1 line
837 B
C++
Executable File
1 line
837 B
C++
Executable File
/* Special Conformance Test 4.6.3.5: Verification of pointer initialization: */
|
|
/* setting pointer to integer constant */
|
|
/* */
|
|
/* Tester needs to enter one character from the keyboard and then check that */
|
|
/* the key echoed is the same key. */
|
|
/* */
|
|
|
|
main ()
|
|
{
|
|
static char *keyBoard = (char *) 0xC000ul, *strobe = (char *) 0xC010ul, ch;
|
|
|
|
*keyBoard = 0;
|
|
printf ("Please type one character\n");
|
|
while (!(*keyBoard & 0x0080)) ;
|
|
*strobe = 1;
|
|
ch = *keyBoard;
|
|
printf ("The character typed is: %c\n", ch);
|
|
return;
|
|
|
|
Fail:
|
|
printf ("Failed Special Conformance Test 4.6.3.5\n");
|
|
}
|