Higlorsplitz.
It works on my pi2 :
Code:
root@nwrap:~# acpi -?
acpi <temp|tension|acpi|freq|codec|mem|config [int|str|config_option_name]>
acpi -? : unsupported
root@nwrap:~# acpi config
arm_freq=900
audio_pwm_mode=1
config_hdmi_boost=5
disable_commandline_tags=2
disable_l2cache=1
enable_uart=1
force_eeprom_read=1
force_pwm_open=1
framebuffer_ignore_alpha=1
framebuffer_swap=1
hdmi_force_cec_address=65535
hdmi_force_edid_audio=1
init_uart_clock=0x2dc6c00
lcd_framerate=60
mask_gpu_interrupt1=0x10000
over_voltage_avs=0x1b774
overscan_bottom=37
overscan_left=37
overscan_right=37
overscan_top=37
pause_burst_frames=1
program_serial_random=1
sdram_freq=450
temp_limit=85
device_tree=-
root@nwrap:~#
Yes if you input unsupported option you get back that message ... it's telling you what it supports:
you called it temps (I called it acpi). It's telling you that an option argument is mandatory and can be any one of:
- temp
- tension
- acpi
- freq
- codec
- mem
- config [int|str|config_option_name]
I think you're just using it wrong ... try using option "all" that gives you everything but the config.
${2:-all} simply means use the second option string if present else use "all" (bash reference manual if in doubt).
So if you tell it you want config and omit whether you want string or integer config options you get both back.
If you want the temperature reading you should be typing
Code:
case ${1:-$NAME} in
Means that if $1 is not set use the name of the script itself ... now I called it acpi so acpi is a supported option and gives you back temperature and voltages, in your case temps is not a supported option so you get an error message if you just type temps with no arguments.