| | 2 | |
| | 3 | == Overview == |
| | 4 | For testing some device drivers may be loaded or unloaded dynamically or a startup script may be used to automatically load the modules. |
| | 5 | |
| | 6 | ||'''Driver'''||'''Module Filename'''||'''Device Nodes'''||'''Depends on other modules'''|| |
| | 7 | ||Mainboard communications||mnbd-comm.ko||/dev/mnbd[[BR]]/dev/wt1 ..[[BR]][[BR]]/dev/wt10|||| |
| | 8 | ||USB Hub||isp1520.ko||||i2c-mcf, i2c-core|| |
| | 9 | ||Keypad/Beeper||max734x.ko||/dev/cardbeep||I2c-mcf, i2c-core|| |
| | 10 | |
| | 11 | Device driver operation may be tested from command line for some functions, for example: |
| | 12 | |
| | 13 | {{{ |
| | 14 | # echo “A,B,C” > /dev/cardbeep <CR> |
| | 15 | }}} |
| | 16 | Play notes A, B, and C on beeper. ''(refer to beeper section for more details)'' |
| | 17 | |
| | 18 | {{{ |
| | 19 | # echo “W” > /dev/wt1 <CR> |
| | 20 | }}} |
| | 21 | Request weight from scale one. |
| | 22 | |
| | 23 | {{{ |
| | 24 | # cat < /dev/wt1 <CR> |
| | 25 | }}} |
| | 26 | Display response to previous request from scale 1 as a weight structure converted to hexadecimal. |
| | 27 | |
| | 28 | {{{ |
| | 29 | #!Lineno |
| | 30 | #!c |
| | 31 | 01004812B682000000004812B6820003 |
| | 32 | |
| | 33 | struct mnbd_wt_struct |
| | 34 | { |
| | 35 | unsigned char interval; (01 – interval 1) |
| | 36 | unsigned char decimal; (00 – no decimal) |
| | 37 | float grosswt; (4812B682 – IEEE floating point value) |
| | 38 | float tarewt; (00000000 – IEEE floating point value–tare zero) |
| | 39 | float netwt; (4812B682 – IEEE floating point value) |
| | 40 | unsigned char units; (00 – units) |
| | 41 | unsigned char status; (03 – status) |
| | 42 | }; |
| | 43 | }}} |
| | 44 | |
| | 45 | [[Top]] |