在按键中断实验中,轻触键key0,key1,key2和key3分别与pio[0],pio[1],pio[2]和pio[3]相连,即key0接pio的低位,key3接pio的高位。已知按下轻触键,key=0;不按下,key=1。如果key3按下,执行以下语句后,变量edge__value的值是()
edge__value =IORD__AVALON__EDGE_CAP(__);
A: edge_capture_value=0x1;
B: edge_capture_value=0x2;
C: edge_capture_value=0x4;
D: edge_capture_value=0x8;
edge__value =IORD__AVALON__EDGE_CAP(__);
A: edge_capture_value=0x1;
B: edge_capture_value=0x2;
C: edge_capture_value=0x4;
D: edge_capture_value=0x8;
举一反三
- 在按键中断实验中,轻触键key0,key1,key2和key3分别与pio[0],pio[1],pio[2]和pio[3]相连,即key0接pio的低位,key3接pio的高位。已知按下轻触键,key=0;不按下,key=1。如果key3按下,执行以下语句后,变量edge_cap_value的值是()。edge_cap_value=IORD_ALTERA_AVALON_PIO_EDGE_CAP (KEY_PIO_BASE); A: edge_cap_value=0x1; B: edge_cap_value=0x2; C: edge_cap_value=0x4; D: edge_cap_value=0x8;
- 等待按键按下后松开的语句是() A: while(key==0) B: if(key==0); C: while(key=0); D: if(key=0);
- x = { 'key': 'value' } print(x[0]) 上述代码输出结果为____。 A: ‘key’: ‘value’ B: 无法执行 C: ‘key’ D: ‘value’
- How many key comparisons are needed in searching for key value 38() A: 1 B: 2 C: 3 D: 4
- 判断按键是否按下的编程程序正确的是( ) A: if(key==0){…..}else{ ……} B: if(key=0){…..}else{ ……} C: while(key==0){ ……} D: while(key=0){ ……}