HI
desperately trying to get this to work, but i cant seem to get the command right:
I’m still on Hassio .62.1
I get through the setup without errors , but no output yet. Please forgive my asking, but how could these 4 commands , while being identical except for the .png file, get 4 different results? Don’t they ‘command’ the same??
this is what i get right now. Looking fine, no info of use though ;-(((

latest command_line sensor efforts:
sensor:
- platform: command_line
name: Epson ink level Black
command: /usr/bin/curl -X GET http://192.168.xxx.xxx | awk -F "'" '/Ink_K.PNG/ { printf "%.0f\n", $6 / 50 * 100; exit }'
unit_of_measurement: '%'
scan_interval: 14400
- platform: command_line
name: Epson ink level Magenta
command: /usr/bin/curl -X GET http://192.168.xxx.xxx | awk -F "'" '/Ink_M.PNG/ { printf "%.0f\n", $6 / 50 * 100; exit }'
unit_of_measurement: '%'
scan_interval: 14400
- platform: command_line
name: Epson ink level Yellow
command: /usr/bin/curl -X GET http://192.168.xxx.xxx | awk -F " " '/Ink_Y.PNG/ { getline; print $6; exit}' | awk -F "px" '{ printf "%.0f\n", (50 - $1) / 50 * 100; exit}'
unit_of_measurement: '%'
scan_interval: 14400
- platform: command_line
name: Epson ink level Cyan
command: /usr/bin/curl -X GET http://192.168.xxx.xxx | awk -F " " '/Ink_C.PNG/ { getline; print $6; exit}' | awk -F "px" '{ printf "%.0f\n", (50 - $1) / 50 * 100; exit}'
unit_of_measurement: '%'
scan_interval: 14400
Please have a look?
btw the 3640 also has an Icn_Mb.PNG
for the Maintenance Box…
Marius