George Keishing | d2795d6 | 2018-02-04 23:12:23 -0600 | [diff] [blame] | 1 | #!/usr/bin/env python |
| 2 | |
| 3 | r""" |
George Keishing | dcf746b | 2018-02-06 12:43:44 -0600 | [diff] [blame] | 4 | IPMI raw commands table: |
George Keishing | d2795d6 | 2018-02-04 23:12:23 -0600 | [diff] [blame] | 5 | |
| 6 | - Define IPMI interface index, commands and expected output. |
| 7 | |
| 8 | """ |
| 9 | |
| 10 | IPMI_RAW_CMD = { |
| 11 | # Interface name |
| 12 | 'power_supply_redundancy': |
| 13 | { |
| 14 | # Command action type |
| 15 | 'Get': |
| 16 | [ |
| 17 | # raw command, expected output(s), comment |
| 18 | "0x04 0x2d 0x0b", |
| 19 | "00 00 01 00", |
| 20 | "Byte position 3rd LSB e.g. 01 indicates disabled", |
| 21 | "00 00 02 00", |
| 22 | "Byte position 3rd LSB e.g. 02 indicates enabled", |
| 23 | ], |
| 24 | 'Enabled': |
| 25 | [ |
| 26 | # raw command, expected output, comment |
| 27 | "0x04 0x30 0x0b 0x00 0x00 0x02 0x00 0x00 0x00 0x00 0x00 0x00", |
| 28 | "none", |
| 29 | "Enabled nibble position 6th LSB e.g. 0x2", |
| 30 | ], |
| 31 | 'Disabled': |
| 32 | [ |
| 33 | # raw command, expected output, comment |
| 34 | "0x04 0x30 0x0b 0x00 0x00 0x01 0x00 0x00 0x00 0x00 0x00 0x00", |
| 35 | "none", |
| 36 | "Enabled nibble position 6th LSB e.g. 0x1", |
| 37 | ], |
Rahul Maheshwari | abe13af | 2018-02-15 22:42:08 -0600 | [diff] [blame] | 38 | }, |
| 39 | 'power_reading': |
| 40 | { |
| 41 | 'Get': |
| 42 | [ |
| 43 | # raw command, expected output(s), comment |
| 44 | "0x2c 0x02 0xdc 0x01 0x01 0x00", |
| 45 | "dc d5 00 d5 00 d5 00 d5 00 00 00 00 00 00 00 00 00 00", |
| 46 | "Byte position 2nd LSB e.g. d5 Instantaneous power readings", |
| 47 | ], |
George Keishing | d2795d6 | 2018-02-04 23:12:23 -0600 | [diff] [blame] | 48 | } |
| 49 | } |