CS 380 Lab 4 Keyboard Input Assigned 2/11/10 30 Points

Size: px
Start display at page:

Download "CS 380 Lab 4 Keyboard Input Assigned 2/11/10 30 Points"

Transcription

1 CS 380 ab 4 Keyboard Input Assigned 2/11/10 30 Points In this lab we will see how a kernel can get data from the keyboard. We will adapt code to allow us to perform a number of important operations. Part 1 Keyboards support one or more of three broad keyboard types. Each type has a value assigned to each key. These values are called scan codes. The default scan code supported by all modern keyboards is the Scan Code Set 2. The mapping for scan codes 1 and 2 are found in appendices A and B. The INTE 8042 microcontroller converts electrical signals from the keyboard and generates a series of make and break codes for each key. A make code is generated whenever a key is pressed. A break code is generated whenever a key is released. A repeat code is also generated when a key is held down longer than the typematic delay. We need to get the make code in order to determine which key/character was pressed. In addition, we need to know the state of the keyboard. For example, if the A key was pressed, was it pressed in combination with the shift or alt keys. Most make and break codes are one byte long. However, other codes are 2 to 4 bytes long. These longer make codes start with an E0, E1, or F0. Single byte break codes always have the most significant bit set to a 1. Getting a Scan Code Scan codes are obtained through interrupts or by polling. Since we haven t set up interrupts yet. We will need to use polling. To get a scan code from the INTE 8042, the byte is read from port 0x60. The byte may or not be ready to be read. In order to determine if the scan code is ready to be read, port 0x64 is read and the least significant bit is checked. If the bit is a zero then the scan code is not ready to be read. If the bit is a one then the scan code can be read from port 0x60. To read a byte from a port use the following function which uses inline assembly code: inline unsigned char inportb(unsigned short port) { unsigned char ret_val; asm volatile("inb %w1,%b0" : "=a"(ret_val) 1

2 ; : "d"(port)); return ret_val; Exercise Add the following functions to your kernel from ab 3: Function void putchar(char c); char getscancode(); Purpose Displays a character at the current cursor position and advance the cursor by one position. Returns a scan code form the keyboard Test these function in your kernel. When the user enters a character don t try to display that character. Instead, display a single character such as the pound symbol. Part 2 Scan codes are nice but need to be converted to determine what is the actual character. The table in Appendices A and B hints at how a function could be written to convert scan codes to characters. However, two functions have been provided to assist in this process: ScanCode2Ascii Converts scan codes to a short number SetsKybdState Sets up the state of the keyboard These two functions and related declarations are found in Appendix C. Exercise Incorporate these functions into your kernel so that you are able to read and display common ASCII characters. The general process will be to: 1) Use getscancode to get a scan code 2) Use SetsKybdState with the scan code to set the state 3) Check to see of the scan code is a break code, if so ignore it 4) Use ScanCode2Ascii to convert a valid scan code to a short value 5) Extract the ASCII character and display it using putchar 2

3 Appendix A - Keyboard Scan Codes: Set 1 Source: *All values are in hexadecimal 101-, 102-, and 104-key keyboards: KE Y MAK E BREA K KEY MAKE BREA K KEY MAK E BREA K A 1E 9E 9 0A 8A [ 1A 9A B 30 B0 ` INSER T E0,52 E0,D2 C 2E AE - 0C 8C HOME E0,47 E0,97 D 20 A0 = 0D 8D PG UP E0,49 E0,C9 E \ 2B AB DEET E E0,53 E0,D3 F 21 A1 BKSP 0E 8E END E0,4F E0,CF G 22 A2 SPACE 39 B9 PG DN E0,51 E0,D1 H 23 A3 TAB 0F 8F I CAPS 3A BA J 24 A4 K 25 A5 SHFT CTR 2A 1D AA 9D U D R E0,48 E0,C8 E0,4B E0,CB E0,50 E0,D0 E0,4D E0,CD 26 A6 GUI E0,5B E0,DB NUM 45 C5 M 32 B2 AT 38 B8 KP / E0,35 E0,B5 N 31 B1 O R SHFT R CTR 36 B6 KP * 37 B7 E0,1D E0,9D KP - 4A CA P R GUI E0,5C E0,DC KP + 4E CE Q R AT E0,38 E0,B8 KP EN E0,1C E0,9C R APPS E0,5D E0,DD KP. 53 D3 S 1F 9F ENTER 1C 9C KP 0 52 D2 T ESC KP 1 4F CF U F1 3B BB KP 2 50 D0 V 2F AF F2 3C BC KP 3 51 D1 W F3 3D BD KP 4 4B CB 3

4 X 2D AD F4 3E BE KP 5 4C CC Y F5 3F BF KP 6 4D CD Z 2C AC F6 40 C0 KP 7 47 C7 0 0B 8B F7 41 C1 KP 8 48 C F8 42 C2 KP 9 49 C F9 43 C3 ] 1B 9B F10 44 C4 ; 27 A F11 57 D7 ' 28 A F12 58 D8, 33 B PRNT SCRN SCRO PAUSE ACPI Scan Codes: E0,2A, E0,37 E0,B7, E0,AA. 34 B4 46 C6 / 35 B5 E1,1D,4 5 E1,9D,C 5 -NONE- Key Make Code Break Code Power E0, 5E E0, DE Sleep E0, 5F E0, DF Wake E0, 63 E0, E3 Windows Multimedia Scan Codes: Key Make Code Break Code Next Track E0, 19 E0, 99 Previous Track E0, 10 E0, 90 Stop E0, 24 E0, A4 Play/Pause E0, 22 E0, A2 Mute E0, 20 E0, A0 Volume Up E0, 30 E0, B0 Volume Down E0, 2E E0, AE Media Select E0, 6D E0, ED E0, 6C E0, EC Calculator E0, 21 E0, A1 My Computer E0, 6B E0, EB 4

5 WWW Search E0, 65 E0, E5 WWW Home E0, 32 E0, B2 WWW Back E0, 6A E0, EA WWW Forward E0, 69 E0, E9 WWW Stop E0, 68 E0, E8 WWW Refresh E0, 67 E0, E7 WWW Favorites E0, 66 E0, E6 5

6 Appendix B - Keyboard Scan Codes: Set 2 *All values are in hexadecimal 101-, 102-, and 104-key keyboards: KE Y MAK E BREA K KEY MAKE BREAK KEY MAK E BREAK A 1C F0,1C 9 46 F0,46 [ 54 FO,54 B 32 F0,32 ` 0E F0,0E INSER T E0,70 E0,F0,7 0 C 21 F0,21-4E F0,4E HOME E0,6C E0,F0,6 C D 23 F0,23 = 55 FO,55 PG UP E0,7D E0,F0,7 D E 24 F0,24 \ 5D F0,5D DEET E E0,71 E0,F0,7 1 F 2B F0,2B BKSP 66 F0,66 END E0,69 E0,F0,6 9 G 34 F0,34 SPACE 29 F0,29 PG DN E0,7A E0,F0,7 A H 33 F0,33 TAB 0D F0,0D I 43 F0,43 CAPS 58 F0,58 J 3B F0,3B K 42 F0,42 SHFT CTR 4B F0,4B GUI E0,1F 12 FO,12 14 FO,14 E0,F0,1 F U D R E0,F0,7 E0,75 5 E0,F0,6 E0,6B B E0,F0,7 E0,72 2 E0,F0,7 E0,74 4 NUM 77 F0,77 M 3A F0,3A AT 11 F0,11 KP / E0,4A E0,F0,4 A R N 31 F0,31 59 F0,59 KP * 7C F0,7C SHFT O 44 F0,44 R CTR E0,14 P 4D F0,4D R GUI E0,27 Q 15 F0,15 R AT E0,11 R 2D F0,2D APPS E0,2F E0,F0,1 4 E0,F0,2 7 E0,F0,1 1 E0,F0,2 F KP - 7B F0,7B KP + 79 F0,79 KP EN E0,5A E0,F0,5 A KP. 71 F0,71 S 1B F0,1B ENTER 5A F0,5A KP 0 70 F0,70 T 2C F0,2C ESC 76 F0,76 KP 1 69 F0,69 U 3C F0,3C F1 05 F0,05 KP 2 72 F0,72 V 2A F0,2A F2 06 F0,06 KP 3 7A F0,7A 6

7 W 1D F0,1D F3 04 F0,04 KP 4 6B F0,6B X 22 F0,22 F4 0C F0,0C KP 5 73 F0,73 Y 35 F0,35 F5 03 F0,03 KP 6 74 F0,74 Z 1A F0,1A F6 0B F0,0B KP 7 6C F0,6C 0 45 F0,45 F7 83 F0,83 KP 8 75 F0, F0,16 F8 0A F0,0A KP 9 7D F0,7D 2 1E F0,1E F9 01 F0,01 ] 5B F0,5B 3 26 F0,26 F10 09 F0,09 ; 4C F0,4C 4 25 F0,25 F11 78 F0,78 ' 52 F0,52 5 2E F0,2E F12 07 F0,07, 41 F0, F0,36 7 3D F0,3D PRNT SCRN SCRO 8 3E F0,3E PAUSE E0,12, E0,7C E0,F0, 7C,E0, F0, F0,49 7E F0,7E / 4A F0,4A E1,14,77, E1,F0,14, F0,77 -NONE- ACPI Scan Codes: Key Make Code Break Code Power E0, 37 E0, F0, 37 Sleep E0, 3F E0, F0, 3F Wake E0, 5E E0, F0, 5E Windows Multimedia Scan Codes: Key Make Code Break Code Next Track E0, 4D E0, F0, 4D Previous Track E0, 15 E0, F0, 15 Stop E0, 3B E0, F0, 3B Play/Pause E0, 34 E0, F0, 34 Mute E0, 23 E0, F0, 23 Volume Up E0, 32 E0, F0, 32 Volume Down E0, 21 E0, F0, 21 Media Select E0, 50 E0, F0, 50 E0, 48 E0, F0, 48 7

8 Calculator E0, 2B E0, F0, 2B My Computer E0, 40 E0, F0, 40 WWW Search E0, 10 E0, F0, 10 WWW Home E0, 3A E0, F0, 3A WWW Back E0, 38 E0, F0, 38 WWW Forward E0, 30 E0, F0, 30 WWW Stop E0, 28 E0, F0, 28 WWW Refresh E0, 20 E0, F0, 20 WWW Favorites E0, 18 E0, F0, 18 8

9 Appendix C /* ============================================================ This code is adapted from the keyboard GCC files ============================================================ */ typedef int typedef unsigned char typedef unsigned short int typedef unsigned long int #defineprivate static BOO; BYTE8; WORD16; DWORD32; #ifndef TRUE #definetrue 1 #endif #ifndef FASE #definefase 0 #endif #defineentries(a) (sizeof(a)/sizeof(a[0])) typedef struct STATE { BOO ins ; BOO rshift ; BOO lshift ; BOO alt ; BOO ctrl ; BOO caps ; BOO scrl ; BOO num ; attribute ((packed)) STATE ; #definekybd_sts_port 0x64 #definekybd_dat_port 0x60 #definekybd_dat_rdy 0x01 #definebreak_code 0x80 #definesize 20 PRIVATE STATE state ; /* Initialized to all FASE by loader */ 9

10 PRIVATE BYTE8 scan_codes[size] ; PRIVATE unsigned int nq = 0 ; PRIVATE unsigned int dq = 0 ; PRIVATE unsigned int count = 0 ; /* */ /* Scan code translation table. */ /* The incoming scan code from the keyboard selects a row. */ /* The modifier status selects the column. */ /* The word at the intersection of the two is the scan/ascii code to */ /* put into the PC's type ahead buffer. */ /* If the value fetched from the table is zero, then we do not put the */ /* character into the type ahead buffer. */ /* */ PRIVATE WORD16 scan_ascii[][8] = { /* norm, shft, ctrl, alt, num, caps, shcap, shnum */ /*--*/ {0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*ESC*/ {0x011B, 0x011B, 0x011B, 0x011B, 0x011B, 0x011B, 0x011B, 0x011B, /*1!*/ {0x0231, 0x0221, 0x0000, 0x7800, 0x0231, 0x0231, 0x0231, 0x0321, {0x0332, 0x0340, 0x0300, 0x7900, 0x0332, 0x0332, 0x0332, 0x0332, /*3 #*/ {0x0433, 0x0423, 0x0000, 0x7A00, 0x0433, 0x0433, 0x0423, 0x0423, /*4 $*/ {0x0534, 0x0524, 0x0000, 0x7B00, 0x0534, 0x0534, 0x0524, 0x0524, /*5 %*/ {0x0635, 0x0625, 0x0000, 0x7C00, 0x0635, 0x0635, 0x0625, 0x0625, /*6 ^*/ {0x0736, 0x075E, 0x071E, 0x7D00, 0x0736, 0x0736, 0x075E, 0x075E, /*7 &*/ {0x0837, 0x0826, 0x0000, 0x7E00, 0x0837, 0x0837, 0x0826, 0x0826, /*8 **/ {0x0938, 0x092A, 0x0000, 0x7F00, 0x0938, 0x0938, 0x092A, 0x092A, /*9 (*/ {0x0A39, 0x0A28, 0x0000, 0x8000, 0x0A39, 0x0A39, 0x0A28, 0x0A28, /*0 )*/ {0x0B30, 0x0B29, 0x0000, 0x8100, 0x0B30, 0x0B30, 0x0B29, 0x0B29, /*- _*/ {0x0C2D, 0x0C5F, 0x0000, 0x8200, 0x0C2D, 0x0C2D, 0x0C5F, 0x0C5F, /*= +*/ {0x0D3D, 0x0D2B, 0x0000, 0x8300, 0x0D3D, 0x0D3D, 0x0D2B, 0x0D2B, /*bksp*/ {0x0E08, 0x0E08, 0x0E7F, 0x0000, 0x0E08, 0x0E08, 0x0E08, 0x0E08, /*Tab*/ {0x0F09, 0x0F00, 0x0000, 0x0000, 0x0F09, 0x0F09, 0x0F00, 0x0F00, /*Q*/ {0x1071, 0x1051, 0x1011, 0x1000, 0x1071, 0x1051, 0x1051, 0x1071, /*W*/ {0x1177, 0x1057, 0x1017, 0x1100, 0x1077, 0x1057, 0x1057, 0x1077, /*E*/ {0x1265, 0x1245, 0x1205, 0x1200, 0x1265, 0x1245, 0x1245, 0x1265, /*R*/ {0x1372, 0x1352, 0x1312, 0x1300, 0x1272, 0x1252, 0x1252, 0x1272, /*T*/ {0x1474, 0x1454, 0x1414, 0x1400, 0x1474, 0x1454, 0x1454, 0x1474, /*Y*/ {0x1579, 0x1559, 0x1519, 0x1500, 0x1579, 0x1559, 0x1579, 0x1559, /*U*/ {0x1675, 0x1655, 0x1615, 0x1600, 0x1675, 0x1655, 0x1675, 0x1655, /*I*/ {0x1769, 0x1749, 0x1709, 0x1700, 0x1769, 0x1749, 0x1769, 0x1749, /*O*/ {0x186F, 0x184F, 0x180F, 0x1800, 0x186F, 0x184F, 0x186F, 0x184F, /*P*/ {0x1970, 0x1950, 0x1910, 0x1900, 0x1970, 0x1950, 0x1970, 0x1950, /*[ {*/ {0x1A5B, 0x1A7B, 0x1A1B, 0x0000, 0x1A5B, 0x1A5B, 0x1A7B, 0x1A7B, /*] */ {0x1B5D, 0x1B7D, 0x1B1D, 0x0000, 0x1B5D, 0x1B5D, 0x1B7D, 0x1B7D, /*entr*/ {0x1C0D, 0x1C0D, 0x1C0A, 0x0000, 0x1C0D, 0x1C0D, 0x1C0A, 0x1C0A, /*ctrl*/ {0x1D00, 0x1D00, 0x1D00, 0x1D00, 0x1D00, 0x1D00, 0x1D00, 0x1D00, /*A*/ {0x1E61, 0x1E41, 0x1E01, 0x1E00, 0x1E61, 0x1E41, 0x1E61, 0x1E41, /*S*/ {0x1F73, 0x1F53, 0x1F13, 0x1F00, 0x1F73, 0x1F53, 0x1F73, 0x1F53, /*D*/ {0x2064, 0x2044, 0x2004, 0x2000, 0x2064, 0x2044, 0x2064, 0x2044, /*F*/ {0x2166, 0x2146, 0x2106, 0x2100, 0x2166, 0x2146, 0x2166, 0x2146, /*G*/ {0x2267, 0x2247, 0x2207, 0x2200, 0x2267, 0x2247, 0x2267, 0x2247, /*H*/ {0x2368, 0x2348, 0x2308, 0x2300, 0x2368, 0x2348, 0x2368, 0x2348, /*J*/ {0x246A, 0x244A, 0x240A, 0x2400, 0x246A, 0x244A, 0x246A, 0x244A, 10

11 /*K*/ {0x256B, 0x254B, 0x250B, 0x2500, 0x256B, 0x254B, 0x256B, 0x254B, /**/ {0x266C, 0x264C, 0x260C, 0x2600, 0x266C, 0x264C, 0x266C, 0x264C, /*; :*/ {0x273B, 0x273A, 0x0000, 0x0000, 0x273B, 0x273B, 0x273A, 0x273A, /*' "*/ {0x2827, 0x2822, 0x0000, 0x0000, 0x2827, 0x2827, 0x2822, 0x2822, /*` ~*/ {0x2960, 0x297E, 0x0000, 0x0000, 0x2960, 0x2960, 0x297E, 0x297E, /*Shf*/ {0x2A00, 0x2A00, 0x2A00, 0x2A00, 0x2A00, 0x2A00, 0x2A00, 0x2A00, /*\ */ {0x2B5C, 0x2B7C, 0x2B1C, 0x0000, 0x2B5C, 0x2B5C, 0x2B7C, 0x2B7C, /*Z*/ {0x2C7A, 0x2C5A, 0x2C1A, 0x2C00, 0x2C7A, 0x2C5A, 0x2C7A, 0x2C5A, /*X*/ {0x2D78, 0x2D58, 0x2D18, 0x2D00, 0x2D78, 0x2D58, 0x2D78, 0x2D58, /*C*/ {0x2E63, 0x2E43, 0x2E03, 0x2E00, 0x2E63, 0x2E43, 0x2E63, 0x2E43, /*V*/ {0x2F76, 0x2F56, 0x2F16, 0x2F00, 0x2F76, 0x2F56, 0x2F76, 0x2F56, /*B*/ {0x3062, 0x3042, 0x3002, 0x3000, 0x3062, 0x3042, 0x3062, 0x3042, /*N*/ {0x316E, 0x314E, 0x310E, 0x3100, 0x316E, 0x314E, 0x316E, 0x314E, /*M*/ {0x326D, 0x324D, 0x320D, 0x3200, 0x326D, 0x324D, 0x326D, 0x324D, /*, <*/ {0x332C, 0x333C, 0x0000, 0x0000, 0x332C, 0x332C, 0x333C, 0x333C, /*. >*/ {0x342E, 0x343E, 0x0000, 0x0000, 0x342E, 0x342E, 0x343E, 0x343E, /*/?*/ {0x352F, 0x353F, 0x0000, 0x0000, 0x352F, 0x352F, 0x353F, 0x353F, /*rshf*/ {0x3600, 0x3600, 0x3600, 0x3600, 0x3600, 0x3600, 0x3600, 0x3600, /** PS*/ {0x372A, 0x0000, 0x3710, 0x0000, 0x372A, 0x372A, 0x0000, 0x0000, /*alt*/ {0x3800, 0x3800, 0x3800, 0x3800, 0x3800, 0x3800, 0x3800, 0x3800, /*spc*/ {0x3920, 0x3920, 0x3920, 0x0000, 0x3920, 0x3920, 0x3920, 0x3920, /*caps*/ {0x3A00, 0x3A00, 0x3A00, 0x3A00, 0x3A00, 0x3A00, 0x3A00, 0x3A00, /*F1*/ {0x3B00, 0x5400, 0x5E00, 0x6800, 0x3B00, 0x3B00, 0x5400, 0x5400, /*F2*/ {0x3C00, 0x5500, 0x5F00, 0x6900, 0x3C00, 0x3C00, 0x5500, 0x5500, /*F3*/ {0x3D00, 0x5600, 0x6000, 0x6A00, 0x3D00, 0x3D00, 0x5600, 0x5600, /*F4*/ {0x3E00, 0x5700, 0x6100, 0x6B00, 0x3E00, 0x3E00, 0x5700, 0x5700, /*F5*/ {0x3F00, 0x5800, 0x6200, 0x6C00, 0x3F00, 0x3F00, 0x5800, 0x5800, /*F6*/ {0x4000, 0x5900, 0x6300, 0x6D00, 0x4000, 0x4000, 0x5900, 0x5900, /*F7*/ {0x4100, 0x5A00, 0x6400, 0x6E00, 0x4100, 0x4100, 0x5A00, 0x5A00, /*F8*/ {0x4200, 0x5B00, 0x6500, 0x6F00, 0x4200, 0x4200, 0x5B00, 0x5B00, /*F9*/ {0x4300, 0x5C00, 0x6600, 0x7000, 0x4300, 0x4300, 0x5C00, 0x5C00, /*F10*/ {0x4400, 0x5D00, 0x6700, 0x7100, 0x4400, 0x4400, 0x5D00, 0x5D00, /*num*/ {0x4500, 0x4500, 0x4500, 0x4500, 0x4500, 0x4500, 0x4500, 0x4500, /*scrl*/ {0x4600, 0x4600, 0x4600, 0x4600, 0x4600, 0x4600, 0x4600, 0x4600, /*home*/ {0x4700, 0x4737, 0x7700, 0x0000, 0x4737, 0x4700, 0x4737, 0x4700, /*up*/ {0x4800, 0x4838, 0x0000, 0x0000, 0x4838, 0x4800, 0x4838, 0x4800, /*pgup*/ {0x4900, 0x4939, 0x8400, 0x0000, 0x4939, 0x4900, 0x4939, 0x4900, /*-*/ {0x4A2D, 0x4A2D, 0x0000, 0x0000, 0x4A2D, 0x4A2D, 0x4A2D, 0x4A2D, /*left*/ {0x4B00, 0x4B34, 0x7300, 0x0000, 0x4B34, 0x4B00, 0x4B34, 0x4B00, /*Cntr*/ {0x4C00, 0x4C35, 0x0000, 0x0000, 0x4C35, 0x4C00, 0x4C35, 0x4C00, /*rght*/ {0x4D00, 0x4D36, 0x7400, 0x0000, 0x4D36, 0x4D00, 0x4D36, 0x4D00, /*+*/ {0x4E2B, 0x4E2B, 0x0000, 0x0000, 0x4E2B, 0x4E2B, 0x4E2B, 0x4E2B, /*end*/ {0x4F00, 0x4F31, 0x7500, 0x0000, 0x4F31, 0x4F00, 0x4F31, 0x4F00, /*down*/ {0x5000, 0x5032, 0x0000, 0x0000, 0x5032, 0x5000, 0x5032, 0x5000, /*pgdn*/ {0x5100, 0x5133, 0x7600, 0x0000, 0x5133, 0x5100, 0x5133, 0x5100, /*ins*/ {0x5200, 0x5230, 0x0000, 0x0000, 0x5230, 0x5200, 0x5230, 0x5200, /*del*/ {0x5300, 0x532E, 0x0000, 0x0000, 0x532E, 0x5300, 0x532E, 0x5300, /*--*/ {0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*--*/ {0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*--*/ {0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, /*F11*/ {0x5700, 0x0000, 0x0000, 0x0000, 0x5700, 0x5700, 0x0000, 0x0000, /*F12*/ {0x5800, 0x0000, 0x0000, 0x0000, 0x5800, 0x5800, 0x0000, 0x0000 ; WORD16 ScanCode2Ascii(BYTE8 code) { if (code == 0xE0 code == 0xE1) return 0x0000 ; /* ignore */ if (code & 0x80) return code << 8 ; /* KeyUp */ 11

12 if (code >= ENTRIES(scan_ascii)) return 0x0000 ; /* ignore */ if (state.alt) return scan_ascii[code][3] ; if (state.ctrl) return scan_ascii[code][2] ; if (code >= 0x47) { if (state.num) { if (state.lshift state.rshift) { return scan_ascii[code][7] ; return scan_ascii[code][4] ; else if (state.caps) { if (state.lshift state.rshift) { return scan_ascii[code][6] ; return scan_ascii[code][5] ; if (state.lshift state.rshift) { return scan_ascii[code][1] ; return scan_ascii[code][0] ; BOO SetsKybdState(BYTE8 code) { switch (code) { case 0x36: state.rshift = TRUE ; break ; case 0xB6: state.rshift = FASE ; break ; case 0x2A: state.lshift = TRUE ; break ; case 0xAA: state.lshift = FASE ; break ; case 0x38: state.alt = TRUE ; break ; case 0xB8: state.alt = FASE ; break ; case 0x1D: state.ctrl = TRUE ; break ; case 0x9D: state.ctrl = FASE ; break ; case 0x3A: state.caps =!state.caps ; case 0xBA: break ; case 0x46: state.scrl =!state.scrl ; case 0xC6: break ; 12

13 return TRUE ; case 0x45: state.num =!state.num ; case 0xC5: break ; case 0x52: state.ins =!state.ins ; case 0xD2: break ; default: return FASE ; 13

14 ASCII Table Decimal Octal Hex Binary Value NU (Null char.) SOH (Start of Header) STX (Start of Text) ETX (End of Text) EOT (End of Transmission) ENQ (Enquiry) ACK (Acknowledgment) BE (Bell) BS (Backspace) HT (Horizontal Tab) A F (ine Feed) B VT (Vertical Tab) C FF (Form Feed) D CR (Carriage Return) E SO (Shift Out) F SI (Shift In) DE (Data ink Escape) DC1 (XON) (Device Control 1) DC2 (Device Control 2) DC3 (XOFF)(Device Control 3) DC4 (Device Control 4) NAK (Negative Acknowledgement) SYN (Synchronous Idle) ETB (End of Trans. Block) CAN (Cancel) EM (End of Medium) A SUB (Substitute) B ESC (Escape) C FS (File Separator) D GS (Group Separator) E RS (Request to Send)(Record Separator) F US (Unit Separator) SP (Space) ! (exclamation mark) " (double quote) # (number sign) $ (dollar sign) % (percent) & (ampersand) ' (single quote) ( (left/opening parenthesis) ) (right/closing parenthesis) A * (asterisk) B (plus) C , (comma) D (minus or dash) E (dot) F / (forward slash) A : (colon) B ; (semi-colon) C < (less than) D = (equal sign) E > (greater than) F ? (question mark) (AT symbol) 14

15 A B C D E F G H I A J B K C D M E N F O P Q R S T U V W X Y A Z B [ (left/opening bracket) C \ (back slash) D ] (right/closing bracket) E ^ (caret/cirumflex) F _ (underscore) ` a b c d e f g h i A j B k C l D m E n F o p q r s t u v w x y A z B { (left/opening brace) C (vertical bar) D (right/closing brace) E ~ (tilde) F DE (delete) 15

ASCII Code - The extended ASCII table

ASCII Code - The extended ASCII table ASCII Code - The extended ASCII table ASCII, stands for American Standard Code for Information Interchange. It's a 7-bit character code where every single bit represents a unique character. On this webpage

More information

OOstaExcel.ir. J. Abbasi Syooki. HTML Number. Device Control 1 (oft. XON) Device Control 3 (oft. Negative Acknowledgement

OOstaExcel.ir. J. Abbasi Syooki. HTML Number. Device Control 1 (oft. XON) Device Control 3 (oft. Negative Acknowledgement OOstaExcel.ir J. Abbasi Syooki HTML Name HTML Number دهدهی ا کتال هگزاد سیمال باینری نشانه )کاراکتر( توضیح Null char Start of Heading Start of Text End of Text End of Transmission Enquiry Acknowledgment

More information

FD-011WU. 2D Barcode Reader User Guide V1.6CC

FD-011WU. 2D Barcode Reader User Guide V1.6CC FD-011WU 2D Barcode Reader User Guide V1.6CC Table of Contents 1 Getting Started... 1 1.1 Factory Defaults... 1 2 Communication Interfaces...2 2.1 TTL-232 Interface... 2 2.2 Baud Rate... 3 2.3 Data Bit

More information

CMSC 313 Lecture 03 Multiple-byte data big-endian vs little-endian sign extension Multiplication and division Floating point formats Character Codes

CMSC 313 Lecture 03 Multiple-byte data big-endian vs little-endian sign extension Multiplication and division Floating point formats Character Codes Multiple-byte data CMSC 313 Lecture 03 big-endian vs little-endian sign extension Multiplication and division Floating point formats Character Codes UMBC, CMSC313, Richard Chang 4-5 Chapter

More information

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, FALL 2012

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, FALL 2012 CMSC 33 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 2, FALL 22 TOPICS TODAY Bits of Memory Data formats for negative numbers Modulo arithmetic & two s complement Floating point formats

More information

MK D Imager Barcode Scanner Configuration Guide

MK D Imager Barcode Scanner Configuration Guide MK-5500 2D Imager Barcode Scanner Configuration Guide V1.4 Table of Contents 1 Getting Started... 3 1.1 About This Guide... 3 1.2 Barcode Scanning... 3 1.3 Factory Defaults... 3 2 Communication Interfaces...

More information

BD-6500BT Bluetooth 2D Barcode Scanner Configuration Guide

BD-6500BT Bluetooth 2D Barcode Scanner Configuration Guide BD-6500BT Bluetooth 2D Barcode Scanner Configuration Guide V 2.1 Table of Contents 1 Getting Started. 3 1.1 About This Guide.. 3 1.2 Barcode Scanning.. 3 1.3 Factory Defaults.. 3 1.4 Pairing Cradle 4 1.5

More information

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, SPRING 2013

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, SPRING 2013 CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, SPRING 2013 TOPICS TODAY Bits of Memory Data formats for negative numbers Modulo arithmetic & two s complement Floating point

More information

1. Character/String Data, Expressions & Intrinsic Functions. Numeric Representation of Non-numeric Values. (CHARACTER Data Type), Part 1

1. Character/String Data, Expressions & Intrinsic Functions. Numeric Representation of Non-numeric Values. (CHARACTER Data Type), Part 1 Character/String Data, Expressions Intrinsic Functions (CHARACTER Data Type), Part 1 1. Character/String Data, Expressions Intrinsic Functions (CHARACTER Data Type), Part 1 2. Numeric Representation of

More information

Number Systems II MA1S1. Tristan McLoughlin. November 30, 2013

Number Systems II MA1S1. Tristan McLoughlin. November 30, 2013 Number Systems II MA1S1 Tristan McLoughlin November 30, 2013 http://en.wikipedia.org/wiki/binary numeral system http://accu.org/index.php/articles/18 http://www.binaryconvert.com http://en.wikipedia.org/wiki/ascii

More information

2a. Codes and number systems (continued) How to get the binary representation of an integer: special case of application of the inverse Horner scheme

2a. Codes and number systems (continued) How to get the binary representation of an integer: special case of application of the inverse Horner scheme 2a. Codes and number systems (continued) How to get the binary representation of an integer: special case of application of the inverse Horner scheme repeated (integer) division by two. Example: What is

More information

The following are the data types used in the C programming language:

The following are the data types used in the C programming language: Data Types in C The following are the data types used in the C programming language: Type Definition Size in memory void This particular type is used only in function declaration. boolean It stores false

More information

Characters Lesson Outline

Characters Lesson Outline Outline 1. Outline 2. Numeric Encoding of Non-numeric Data #1 3. Numeric Encoding of Non-numeric Data #2 4. Representing Characters 5. How Characters Are Represented #1 6. How Characters Are Represented

More information

EXPERIMENT 8: Introduction to Universal Serial Asynchronous Receive Transmit (USART)

EXPERIMENT 8: Introduction to Universal Serial Asynchronous Receive Transmit (USART) EXPERIMENT 8: Introduction to Universal Serial Asynchronous Receive Transmit (USART) Objective: Introduction To understand and apply USART command for sending and receiving data Universal Serial Asynchronous

More information

RS-232 Control of the Advantage EQ281/8, EQ282/8 and Advantage SMS200

RS-232 Control of the Advantage EQ281/8, EQ282/8 and Advantage SMS200 RS-232 Control of the Advantage EQ281/8, EQ282/8 and Advantage SMS200 Biamp Systems, 14130 N.W. Science Park, Portland, Oregon 97229 U.S.A. (503) 641-7287 an affiliate of Rauland-Borg Corp. Introduction

More information

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, FALL 2012

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, FALL 2012 CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, FALL 2012 ANNOUNCEMENTS TA Office Hours (ITE 334): Genaro Hernandez, Jr. Mon 10am 12noon Roshan Ghumare Wed 10am 12noon Prof.

More information

EXPERIMENT 7: Introduction to Universal Serial Asynchronous Receive Transmit (USART)

EXPERIMENT 7: Introduction to Universal Serial Asynchronous Receive Transmit (USART) EXPERIMENT 7: Introduction to Universal Serial Asynchronous Receive Transmit (USART) Objective: To understand and apply USART command for sending and receiving data Introduction Universal Serial Asynchronous

More information

Technical Specification. Third Party Control Protocol. AV Revolution

Technical Specification. Third Party Control Protocol. AV Revolution Technical Specification Third Party Control Protocol AV Revolution Document AM-TS-120308 Version 1.0 Page 1 of 31 DOCUMENT DETAILS Document Title: Technical Specification, Third Party Control Protocol,

More information

Chapter 2 Number System

Chapter 2 Number System Chapter 2 Number System Embedded Systems with ARM Cortext-M Updated: Tuesday, January 16, 2018 What you should know.. Before coming to this class Decimal Binary Octal Hex 0 0000 00 0x0 1 0001 01 0x1 2

More information

1.1. INTRODUCTION 1.2. NUMBER SYSTEMS

1.1. INTRODUCTION 1.2. NUMBER SYSTEMS Chapter 1. 1.1. INTRODUCTION Digital computers have brought about the information age that we live in today. Computers are important tools because they can locate and process enormous amounts of information

More information

Chemistry Hour Exam 2

Chemistry Hour Exam 2 Chemistry 838 - Hour Exam 2 Fall 2003 Department of Chemistry Michigan State University East Lansing, MI 48824 Name Student Number Question Points Score 1 15 2 15 3 15 4 15 5 15 6 15 7 15 8 15 9 15 Total

More information

4. Specifications and Additional Information

4. Specifications and Additional Information 4. Specifications and Additional Information AGX52004-1.0 8B/10B Code This section provides information about the data and control codes for Arria GX devices. Code Notation The 8B/10B data and control

More information

Chapter 3. Information Representation

Chapter 3. Information Representation Chapter 3 Information Representation Instruction Set Architecture APPLICATION LEVEL HIGH-ORDER LANGUAGE LEVEL ASSEMBLY LEVEL OPERATING SYSTEM LEVEL INSTRUCTION SET ARCHITECTURE LEVEL 3 MICROCODE LEVEL

More information

Number Representations

Number Representations Simple Arithmetic [Arithm Notes] Number representations Signed numbers Sign-magnitude, ones and twos complement Arithmetic Addition, subtraction, negation, overflow MIPS instructions Logic operations MIPS

More information

CIS-331 Fall 2014 Exam 1 Name: Total of 109 Points Version 1

CIS-331 Fall 2014 Exam 1 Name: Total of 109 Points Version 1 Version 1 1. (24 Points) Show the routing tables for routers A, B, C, and D. Make sure you account for traffic to the Internet. Router A Router B Router C Router D Network Next Hop Next Hop Next Hop Next

More information

2D Barcode Reader User Guide V 1.2.1

2D Barcode Reader User Guide V 1.2.1 2D Barcode Reader User Guide V 1.2.1 Table of Contents 1 Getting Started... 3 1.1 About This Guide... 3 1.2 Barcode Scanning... 3 1.3 Factory Defaults... 3 1.4 Firmware Version Number... 3 2 Communication

More information

2D Hand-held Barcode Scanner User Guide

2D Hand-held Barcode Scanner User Guide 2D Hand-held Barcode Scanner User Guide 2 / 66 Version History Version Description Date V1.0 Initial release. 2016-11-10 V1.01 Add Data Matrix and PDF417 2017-04-25 3 / 66 Content Chapter 1 Getting Started...

More information

Number Systems for Computers. Outline of Introduction. Binary, Octal and Hexadecimal numbers. Issues for Binary Representation of Numbers

Number Systems for Computers. Outline of Introduction. Binary, Octal and Hexadecimal numbers. Issues for Binary Representation of Numbers Outline of Introduction Administrivia What is computer architecture? What do computers do? Representing high level things in binary Data objects: integers, decimals, characters, etc. Memory locations (We

More information

CIS-331 Exam 2 Fall 2015 Total of 105 Points Version 1

CIS-331 Exam 2 Fall 2015 Total of 105 Points Version 1 Version 1 1. (20 Points) Given the class A network address 117.0.0.0 will be divided into multiple subnets. a. (5 Points) How many bits will be necessary to address 4,000 subnets? b. (5 Points) What is

More information

Acquirer JCB EMV Test Card Set

Acquirer JCB EMV Test Card Set Acquirer JCB EMV Test Card Set July, 2017 Powered by Disclaimer Information provided in this document describes capabilities available at the time of developing this document and information available

More information

First Data Dual Interface EMV Test Card Set. Version 1.20

First Data Dual Interface EMV Test Card Set. Version 1.20 First Data Dual Interface EMV Test Card Set August, 2016 Disclaimer Information provided in this document describes capabilities available at the time of developing this document and information available

More information

CIS-331 Fall 2013 Exam 1 Name: Total of 120 Points Version 1

CIS-331 Fall 2013 Exam 1 Name: Total of 120 Points Version 1 Version 1 1. (24 Points) Show the routing tables for routers A, B, C, and D. Make sure you account for traffic to the Internet. NOTE: Router E should only be used for Internet traffic. Router A Router

More information

USB-ASC232. ASCII RS-232 Controlled USB Keyboard and Mouse Cable. User Manual

USB-ASC232. ASCII RS-232 Controlled USB Keyboard and Mouse Cable. User Manual USB-ASC232 ASCII RS-232 Controlled USB Keyboard and Mouse Cable User Manual Thank you for purchasing the model USB-ASC232 Cable HAGSTROM ELECTRONICS, INC. is pleased that you have selected this product

More information

CIS-331 Spring 2016 Exam 1 Name: Total of 109 Points Version 1

CIS-331 Spring 2016 Exam 1 Name: Total of 109 Points Version 1 Version 1 Instructions Write your name on the exam paper. Write your name and version number on the top of the yellow paper. Answer Question 1 on the exam paper. Answer Questions 2-4 on the yellow paper.

More information

CS/ECE 252: INTRODUCTION TO COMPUTER ENGINEERING UNIVERSITY OF WISCONSIN MADISON

CS/ECE 252: INTRODUCTION TO COMPUTER ENGINEERING UNIVERSITY OF WISCONSIN MADISON CS/ECE 252: INTRODUCTION TO COMPUTER ENGINEERING UNIVERSITY OF WISCONSIN MADISON Prof. Gurindar Sohi TAs: Pradip Vallathol and Junaid Khalid Midterm Examination 1 In Class (50 minutes) Friday, September

More information

First Data EMV Test Card Set. Version 1.30

First Data EMV Test Card Set. Version 1.30 First Data EMV Test Card Set.30 January, 2018 Disclaimer Information provided in this document describes capabilities available at the time of developing this document and information available from industry

More information

RS-232 Control of the Advantage DRI

RS-232 Control of the Advantage DRI RS-232 Control of the Advantage DRI Biamp Systems, 14130 N.W. Science Park, Portland, Oregon 97229 U.S.A. (503) 641-7287 an affiliate of Rauland-Borg Corp. Introduction This document contains technical

More information

CS/ECE 252: INTRODUCTION TO COMPUTER ENGINEERING UNIVERSITY OF WISCONSIN MADISON

CS/ECE 252: INTRODUCTION TO COMPUTER ENGINEERING UNIVERSITY OF WISCONSIN MADISON CS/ECE 252: INTRODUCTION TO COMPUTER ENGINEERING UNIVERSITY OF WISCONSIN MADISON Prof. Gurindar Sohi TAs: Junaid Khalid and Pradip Vallathol Midterm Examination 1 In Class (50 minutes) Friday, September

More information

DATA REPRESENTATION. Data Types. Complements. Fixed Point Representations. Floating Point Representations. Other Binary Codes. Error Detection Codes

DATA REPRESENTATION. Data Types. Complements. Fixed Point Representations. Floating Point Representations. Other Binary Codes. Error Detection Codes 1 DATA REPRESENTATION Data Types Complements Fixed Point Representations Floating Point Representations Other Binary Codes Error Detection Codes 2 Data Types DATA REPRESENTATION Information that a Computer

More information

First Data EMV Test Card Set. Version 2.00

First Data EMV Test Card Set. Version 2.00 First Data EMV Test Card Set.00 February, 2018 Disclaimer Information provided in this document describes capabilities available at the time of developing this document and information available from industry

More information

PS232. RS-232 to PS/2 Keyboard Port Adapter Part # SA0009 (Version 4.0) Copyright 2003 L3 Systems, Inc. Redmond

PS232. RS-232 to PS/2 Keyboard Port Adapter Part # SA0009 (Version 4.0) Copyright 2003 L3 Systems, Inc. Redmond PS232 RS-232 to PS/2 Keyboard Port Adapter Part # SA0009 (Version 4.0) Copyright 2003 L3 Systems, Inc. Redmond Quick Reference Command Description Pg ~H Help Screen Displays short command reference 4 ~V

More information

Experiment 3. TITLE Optional: Write here the Title of your program.model SMALL This directive defines the memory model used in the program.

Experiment 3. TITLE Optional: Write here the Title of your program.model SMALL This directive defines the memory model used in the program. Experiment 3 Introduction: In this experiment the students are exposed to the structure of an assembly language program and the definition of data variables and constants. Objectives: Assembly language

More information

Computer Control of the Advantage DRC 4+4

Computer Control of the Advantage DRC 4+4 Computer Control of the Advantage DRC 4+4 Biamp Systems, 14130 N.W. Science Park, Portland, Oregon 97229 U.S.A. (503) 641-7287 an affiliate of Rauland-Borg Corp. Introduction This document contains technical

More information

Do not start the test until instructed to do so!

Do not start the test until instructed to do so! Instructions: Print your name in the space provided below. This examination is closed book and closed notes, aside from the permitted one-page formula sheet. No calculators or other electronic devices

More information

Midterm Exam, Fall 2015 Date: October 29th, 2015

Midterm Exam, Fall 2015 Date: October 29th, 2015 Full Name: Midterm Exam, Fall 2015 Date: October 29th, 2015 Instructions: This midterm exam takes 70 minutes. Read through all the problems and complete the easy ones first. This exam is OPEN BOOK. You

More information

Fundamentals of Programming (C)

Fundamentals of Programming (C) Borrowed from lecturer notes by Omid Jafarinezhad Fundamentals of Programming (C) Group 8 Lecturer: Vahid Khodabakhshi Lecture Number Systems Department of Computer Engineering Outline Numeral Systems

More information

CIS-331 Exam 2 Fall 2014 Total of 105 Points. Version 1

CIS-331 Exam 2 Fall 2014 Total of 105 Points. Version 1 Version 1 1. (20 Points) Given the class A network address 119.0.0.0 will be divided into a maximum of 15,900 subnets. a. (5 Points) How many bits will be necessary to address the 15,900 subnets? b. (5

More information

First Data DCC Test Card Set. Version 1.30

First Data DCC Test Card Set. Version 1.30 First Data DCC Test Card Set.30 April, 2018 Disclaimer Information provided in this document describes capabilities available at the time of developing this document and information available from industry

More information

C1098 JPEG Module User Manual

C1098 JPEG Module User Manual C1098 JPEG Module User Manual General Description C1098 is VGA camera module performs as a JPEG compressed still camera that can be attached to a wireless or PDA host. Users can send out a snapshot command

More information

Locus Engineering Inc

Locus Engineering Inc Locus Engineering Inc PS/2 Keyboard to ASCII Converter PS/2 Keyboard PS/2 to ACII Converter Host Microcontroller FEATURES Decodes PS/2 Scanset 2 keystrokes to a single ASCII byte on make Offload process

More information

Acquirer JCB Dual Interface EMV Test Card Set

Acquirer JCB Dual Interface EMV Test Card Set Acquirer JCB Dual Interface EMV Test Card Set.00 July, 2018 Powered by Disclaimer Information provided in this document describes capabilities available at the time of developing and delivering this document

More information

CIS-331 Exam 2 Spring 2016 Total of 110 Points Version 1

CIS-331 Exam 2 Spring 2016 Total of 110 Points Version 1 Version 1 1. (20 Points) Given the class A network address 121.0.0.0 will be divided into multiple subnets. a. (5 Points) How many bits will be necessary to address 8,100 subnets? b. (5 Points) What is

More information

Data Representation and Binary Arithmetic. Lecture 2

Data Representation and Binary Arithmetic. Lecture 2 Data Representation and Binary Arithmetic Lecture 2 Computer Data Data is stored as binary; 0 s and 1 s Because two-state ( 0 & 1 ) logic elements can be manufactured easily Bit: binary digit (smallest

More information

Exercises Software Development I. 03 Data Representation. Data types, range of values, internal format, literals. October 22nd, 2014

Exercises Software Development I. 03 Data Representation. Data types, range of values, internal format, literals. October 22nd, 2014 Exercises Software Development I 03 Data Representation Data types, range of values, ernal format, literals October 22nd, 2014 Software Development I Wer term 2013/2014 Priv.-Doz. Dipl.-Ing. Dr. Andreas

More information

CS341 *** TURN OFF ALL CELLPHONES *** Practice NAME

CS341 *** TURN OFF ALL CELLPHONES *** Practice NAME CS341 *** TURN OFF ALL CELLPHONES *** Practice Final Exam B. Wilson NAME OPEN BOOK / OPEN NOTES: I GIVE PARTIAL CREDIT! SHOW ALL WORK! 1. Processor Architecture (20 points) a. In a Harvard architecture

More information

Request for Comments: XXXX November Registration of a Georgian Character Set draft-giasher-geostd8-00.txt

Request for Comments: XXXX November Registration of a Georgian Character Set draft-giasher-geostd8-00.txt Internet draft Gia Shervashidze Network Working Group Georgian Internet Avenue Request for Comments: XXXX November 2001 Registration of a Georgian Character Set draft-giasher-geostd8-00.txt Status of this

More information

EE 109 Unit 3. Analog vs. Digital. Analog vs. Digital. Binary Representation Systems ANALOG VS. DIGITAL

EE 109 Unit 3. Analog vs. Digital. Analog vs. Digital. Binary Representation Systems ANALOG VS. DIGITAL 3. 3. EE 9 Unit 3 Binary Representation Systems ANALOG VS. DIGITAL 3.3 3. Analog vs. Digital The analog world is based on continuous events. Observations can take on any (real) value. The digital world

More information

The cache is 4-way set associative, with 4-byte blocks, and 16 total lines

The cache is 4-way set associative, with 4-byte blocks, and 16 total lines Sample Problem 1 Assume the following memory setup: Virtual addresses are 20 bits wide Physical addresses are 15 bits wide The page size if 1KB (2 10 bytes) The TLB is 2-way set associative, with 8 total

More information

3.1. Unit 3. Binary Representation

3.1. Unit 3. Binary Representation 3.1 Unit 3 Binary Representation ANALOG VS. DIGITAL 3.2 3.3 Analog vs. Digital The analog world is based on continuous events. Observations can take on (real) any value. The digital world is based on discrete

More information

Gateway Ascii Command Protocol

Gateway Ascii Command Protocol Gateway Ascii Command Protocol Table Of Contents Introduction....2 Ascii Commands.....3 Messages Received From The Gateway....3 Button Down Message.....3 Button Up Message....3 Button Maintain Message....4

More information

ECHO Process Instrumentation, Inc. Modbus RS485 Module. Operating Instructions. Version 1.0 June 2010

ECHO Process Instrumentation, Inc. Modbus RS485 Module. Operating Instructions. Version 1.0 June 2010 ECHO Process Instrumentation, Inc. Modbus RS485 Module Operating Instructions Version 1.0 June 2010 ECHO Process Instrumentation, Inc. PO Box 800 Shalimar, FL 32579 PH: 850-609-1300 FX: 850-651-4777 EM:

More information

Characters & Strings in C

Characters & Strings in C Recently, we saw this: Characters & Strings in C % cat charweird.c #include main () { /* main */ char c; c = 75; printf("c = %d\n", c); printf("c = %c\n", c); if (c) { printf("c is true\n");

More information

KB232. PS/2 Keyboard RS-232 Adapter Part # SA0008 (Version 3.0) Copyright 2003 L3 Systems, Inc. Redmond

KB232. PS/2 Keyboard RS-232 Adapter Part # SA0008 (Version 3.0) Copyright 2003 L3 Systems, Inc. Redmond KB232 PS/2 Keyboard RS-232 Adapter Part # SA0008 (Version 3.0) Copyright 2003 L3 Systems, Inc. Redmond Command C Displays Configuration String CW= D Lkk=aa,bb P E H V T Quick Reference Notes Field

More information

Interac USA Interoperability EMV Test Card Set

Interac USA Interoperability EMV Test Card Set Interac USA Interoperability EMV Test Card Set.00 April, 2018 Powered by Disclaimer Information provided in this document describes capabilities available at the time of developing this document and information

More information

IPDA014-2D. Embedded 2D Barcode Scan Engine. User Guide

IPDA014-2D. Embedded 2D Barcode Scan Engine. User Guide IPDA014-2D Embedded 2D Barcode Scan Engine User Guide 1 Table Of Contents Chapter 1 Getting Started...8 Introduction...8 About This Guide...8 Barcode Scanning...9 Barcode Programming...9 Factory Defaults...9

More information

EE 109 Unit 2. Analog vs. Digital. Analog vs. Digital. Binary Representation Systems ANALOG VS. DIGITAL

EE 109 Unit 2. Analog vs. Digital. Analog vs. Digital. Binary Representation Systems ANALOG VS. DIGITAL EE 9 Unit Binary Representation Systems ANALOG VS. DIGITAL Analog vs. Digital The analog world is based on continuous events. Observations can take on any (real) value. The digital world is based on discrete

More information

User s Manual. Xi3000 Scanner. Table of Contents

User s Manual. Xi3000 Scanner. Table of Contents Xi3000 Scanner User s Manual Table of Contents Restore Default Settings... 1 Exit Setup without Changes... 1 Configure Through RS232... 1 List Setting... 1 Buzzer Settings... 2 Reading Redundancy Setting...

More information

Motors I Automation I Energy I Transmission & Distribution I Coatings. Modbus RTU CFW701. User s Manual

Motors I Automation I Energy I Transmission & Distribution I Coatings. Modbus RTU CFW701. User s Manual Motors I Automation I Energy I Transmission & Distribution I Coatings Modbus RTU CFW701 User s Manual Modbus RTU User s Manual Series: CFW701 Language: English Document Number: 10001538593 / 00 Publication

More information

CS 537: Introduction to Operating Systems Fall 2015: Midterm Exam #1

CS 537: Introduction to Operating Systems Fall 2015: Midterm Exam #1 CS 537: Introduction to Operating Systems Fall 2015: Midterm Exam #1 This exam is closed book, closed notes. All cell phones must be turned off. No calculators may be used. You have two hours to complete

More information

S-Series Sensor ASCII Protocol v8.1.0

S-Series Sensor ASCII Protocol v8.1.0 S-Series Sensor v8.1.0 Legend: ADR Node/Slave Address TIME STAT Status Byte ERR CTRL Control Byte SP # POS Position DATA TARG Target CHAR VEL Velocity OFF SN CODE PAR # Serial Number Security Code Parameter

More information

EE 109 Unit 2. Binary Representation Systems

EE 109 Unit 2. Binary Representation Systems EE 09 Unit 2 Binary Representation Systems ANALOG VS. DIGITAL 2 3 Analog vs. Digital The analog world is based on continuous events. Observations can take on (real) any value. The digital world is based

More information

CPS 104 Computer Organization and Programming Lecture-2 : Data representations,

CPS 104 Computer Organization and Programming Lecture-2 : Data representations, CPS 104 Computer Organization and Programming Lecture-2 : Data representations, Sep. 1, 1999 Dietolf Ramm http://www.cs.duke.edu/~dr/cps104.html CPS104 Lec2.1 GK&DR Fall 1999 Data Representation Computers

More information

Here is a C function that will print a selected block of bytes from such a memory block, using an array-based view of the necessary logic:

Here is a C function that will print a selected block of bytes from such a memory block, using an array-based view of the necessary logic: Pointer Manipulations Pointer Casts and Data Accesses Viewing Memory The contents of a block of memory may be viewed as a collection of hex nybbles indicating the contents of the byte in the memory region;

More information

2D BARCODE SCANNER CA-SC-20200B

2D BARCODE SCANNER CA-SC-20200B D BARCODE SCANNER CA-SC-B Quick Start Guide Getting Familiar with Your Device Thank you for choosing Capture Bar Code Scanner. All Devices deliver world-class performance for a broad range of applications

More information

Mounting Dimensions / Viewing 2 Mounting Options 3. Wiring Configuration 4. Quick Set up Procedure 5. Changing Intensity 6.

Mounting Dimensions / Viewing 2 Mounting Options 3. Wiring Configuration 4. Quick Set up Procedure 5. Changing Intensity 6. Section Mounting Dimensions / Viewing 2 Mounting Options 3 Section 2 Wiring Configuration 4 Section 3 Quick Set up Procedure 5 Section 4 Changing Intensity 6 Section 5 Option Summary 7 Section 6 Option

More information

RS 232 PINOUTS. 1. We use RJ12 for all of our RS232 interfaces (Link-2-Modbus & Link-2-PC- Serial/RS232). The diagram below shows our pin out.

RS 232 PINOUTS. 1. We use RJ12 for all of our RS232 interfaces (Link-2-Modbus & Link-2-PC- Serial/RS232). The diagram below shows our pin out. RS 232 PINOUTS 1. We use RJ12 for all of our RS232 interfaces (Link-2-Modbus & Link-2-PC- Serial/RS232). The diagram below shows our pin out. 2. A DB9 Female to RJ12 Female Serial/Terminal Modular Adaptor

More information

AutoLISP Module 6 Competency Test No.1

AutoLISP Module 6 Competency Test No.1 AutoCAD Self-paced ecourse AutoLISP Module 6 Competency Test No.1 Learning Outcomes When you have completed this module, you will be able to: 1 Complete a written exam and write an AutoLISP program on

More information

Visual KeyMaker. Programming Software Instructions. Contents A B

Visual KeyMaker. Programming Software Instructions. Contents A B Visual KeyMaker Programming Software Instructions for TLM2260 Programmable Keyboard REV.E May 31, 2007 Quick Start Map A B Introduction Install Visual KeyMaker Contents C Connect Programmable Keyboard

More information

Unit 3. Analog vs. Digital. Analog vs. Digital ANALOG VS. DIGITAL. Binary Representation

Unit 3. Analog vs. Digital. Analog vs. Digital ANALOG VS. DIGITAL. Binary Representation 3.1 3.2 Unit 3 Binary Representation ANALOG VS. DIGITAL 3.3 3.4 Analog vs. Digital The analog world is based on continuous events. Observations can take on (real) any value. The digital world is based

More information

SPARC INTERNATIONAL. Version1 SPARC Keyboard Specification

SPARC INTERNATIONAL. Version1 SPARC Keyboard Specification SPARC INTERNATIONAL Version1 SPARC Keyboard Specification SPARC International, Inc. 3333 Bowers Ave., Suite 280, Santa Clara, CA 95054-3913, 408-748-9111. FAX 408-748-9777 1999, SPARC International Inc.

More information

Data Representa5on. CSC 2400: Computer Systems. What kinds of data do we need to represent?

Data Representa5on. CSC 2400: Computer Systems. What kinds of data do we need to represent? CSC 2400: Computer Systems Data Representa5on What kinds of data do we need to represent? - Numbers signed, unsigned, integers, floating point, complex, rational, irrational, - Text characters, strings,

More information

CIS-331 Final Exam Spring 2015 Total of 115 Points. Version 1

CIS-331 Final Exam Spring 2015 Total of 115 Points. Version 1 Version 1 1. (25 Points) Given that a frame is formatted as follows: And given that a datagram is formatted as follows: And given that a TCP segment is formatted as follows: Assuming no options are present

More information

LC UNI - SSI PUMPS. Clarity Control Module. Code/Rev.: M038/40D Date:

LC UNI - SSI PUMPS. Clarity Control Module. Code/Rev.: M038/40D Date: LC UNI - SSI PUMPS Clarity Control Module ENG Code/Rev.: M038/40D Date: 24.10.2017 Phone: +420 251 013 400 DataApex Ltd. Fax: +420 251 013 401 Petrzilkova 2583/13 clarity@dataapex.com 158 00 Prague 5 www.dataapex.com

More information

Chapter 8. Characters and Strings

Chapter 8. Characters and Strings Chapter 8 Characters and s OJECTIVES After you have read and studied this chapter, you should be able to Declare and manipulate data of the char data type. Write string processing programs using and uffer

More information

n NOPn Unary no operation trap U aaa NOP Nonunary no operation trap i

n NOPn Unary no operation trap U aaa NOP Nonunary no operation trap i Instruction set Instruction Mnemonic Instruction Addressing Status Specifier Mode Bits 0000 0000 STOP Stop execution U 0000 0001 RET Return from CALL U 0000 0010 RETTR Return from trap U 0000 0011 MOVSPA

More information

If your CNC machine memory is full, the PocketDNC gives you more storage, enabling you to store and reload proven programs at a later date.

If your CNC machine memory is full, the PocketDNC gives you more storage, enabling you to store and reload proven programs at a later date. Page 1 of 54 Introduction...3 Important! PocketDNC Licence File...3 What s in the Box...4 Setting up Windows Mobile (Win7 Win8 Win10)...5 www.microsoft.com/en-gb/download/details.aspx?id=3182connect Without

More information

Modbus RTU CFW100. User s Manual. Phone: Fax: Web: -

Modbus RTU CFW100. User s Manual. Phone: Fax: Web:  - Modbus RTU CFW100 User s Manual Modbus RTU User s Manual Series: CFW100 Language: English Document Number: 10002909455 / 00 Publication Date: 06/2014 CONTENTS CONTENTS... 3 ABOUT THIS MANUAL... 5 ABBREVIATIONS

More information

Setup Procedures 2 Batch Setup 3. Bar Code Setup Menu 5. 1 Device Selection and Default. 2 Beep and Delay Keyboard Wedge..

Setup Procedures 2 Batch Setup 3. Bar Code Setup Menu 5. 1 Device Selection and Default. 2 Beep and Delay Keyboard Wedge.. Contents Setup Procedures 2 Batch Setup 3 Bar Code Setup Menu 5 1 Device Selection and Default 5 2 Beep and Delay... 7 3 Keyboard Wedge.. 9 4 RS232 Serial Setting.... 11 5 Scanner.. 13 7 Symbologies(I):

More information

Configuration Manual PULSAR C CCD SCANNER. Table of Contents

Configuration Manual PULSAR C CCD SCANNER. Table of Contents Table of Contents PULSAR C CCD SCANNER Configuration Manual Metrologic Instruments GmbH Dornier Strasse 2 82178 Puchheim Germany Tel +49 89 890190 Fax +49 89 89019200 www.europe.metrologic.com Metrologic

More information

Parallax Serial LCD 2 rows x 16 characters Non-backlit (#27976) 2 rows x 16 characters Backlit (#27977) 4 rows x 20 characters Backlit (#27979)

Parallax Serial LCD 2 rows x 16 characters Non-backlit (#27976) 2 rows x 16 characters Backlit (#27977) 4 rows x 20 characters Backlit (#27979) 599 Menlo Drive, Suite 100 Rocklin, California 95765, USA Office: (916) 624-8333 Fax: (916) 624-8003 General: info@parallax.com Technical: support@parallax.com Web Site: www.parallax.com Educational: www.stampsinclass.com

More information

July Registration of a Cyrillic Character Set. Status of this Memo

July Registration of a Cyrillic Character Set. Status of this Memo Network Working Group Request for Comments: 1489 A. Chernov RELCOM Development Team July 1993 Status of this Memo Registration of a Cyrillic Character Set This memo provides information for the Internet

More information

Fundamentals of Programming

Fundamentals of Programming Fundamentals of Programming Lecture 2 Number Systems & Arithmetic Lecturer : Ebrahim Jahandar Some Parts borrowed from slides by IETC1011-Yourk University Common Number Systems System Base Symbols Used

More information

Data Representa5on. CSC 2400: Computer Systems. What kinds of data do we need to represent?

Data Representa5on. CSC 2400: Computer Systems. What kinds of data do we need to represent? CSC 2400: Computer Systems Data Representa5on What kinds of data do we need to represent? - Numbers signed, unsigned, integers, floating point, complex, rational, irrational, - Text characters, strings,

More information

J2 LCM Customer Display. Manual

J2 LCM Customer Display. Manual J2 LCM Customer Display Manual July 2012 Contents LCM Customer Display... 3 Overview... 3 Customer Display Configureation... 4 Port Settings... 4 CD Settings... 5 Emulation Mode... 5 Character Sets...

More information

Do not start the test until instructed to do so!

Do not start the test until instructed to do so! Instructions: Print your name in the space provided below. This examination is closed book and closed notes, aside from the permitted one-page formula sheet. No calculators or other electronic devices

More information

Chapter 2 Bits, Data Types, and Operations

Chapter 2 Bits, Data Types, and Operations Chapter Bits, Data Types, and Operations How do we represent data in a computer? At the lowest level, a computer is an electronic machine. works by controlling the flow of electrons Easy to recognize two

More information

Positional Number System

Positional Number System Positional Number System A number is represented by a string of digits where each digit position has an associated weight. The weight is based on the radix of the number system. Some common radices: Decimal.

More information

User s Manual. Addendum to. Ranger Wedge Interface. Part No. 25-WEDGE-06A Ver. April 1999

User s Manual. Addendum to. Ranger Wedge Interface. Part No. 25-WEDGE-06A Ver. April 1999 Addendum to User s Manual Ranger Wedge Interface Part No. 25-WEDGE-06A Ver. April 1999 8 Olympic Drive Orangeburg, NY 10962 Tel 845.365.0090 Fax 845.365.1251 www.opticonusa.com Table of Contents Read Me

More information

ZN-DN312XE-M Quick User Guide

ZN-DN312XE-M Quick User Guide ZN-DN312XE-M Quick User Guide This manual provides instructions for quick installation and basic configuration of your IP device. Step1. Connect cables to IP device Connect required cables to the device

More information

marson MT8200S 2D Handheld Scanner User Manual V / 6 / 25 - I -

marson MT8200S 2D Handheld Scanner User Manual V / 6 / 25 - I - marson MT8200S 2D Handheld Scanner User Manual V1.1 2018 / 6 / 25 - I - Table of Contents 1 Gettting Started...1 1.1 Introduction...1 1.2 Configuring MT8200S...1 1.2.1 Barcode Configurability...1 1.2.2

More information