My printer is not printing well. i think that it printer ink issue. It doesn’t prints black while i use black color ink. Other than this it also skips some letters or we can say that missing colors. I tried many methods to solve this issue but nothing happens. Should i have to visit canon printer offline for the suggestion.
I am trying to install Printer drivers for HP Printer, it gives Error 5 again and again. looking for more posts for resolving the same issue. Dell Printer Support
For HP Envy you can try the HPLIP, i’m using this and 2 command lines to get the inkt level and put then into a txt file. It runs like every 2 hours to update the txt file. Using a TXT file with the level to make sure there is a value after restarting without polling the printer 100 times a day, it is not that fast and gives time-out quickly. It is a quick and dirty solution but you could try:
sudo apt-get install hplip
Setup your printer: (IP of printer)
$ hp-setup -i 192.168.1.2
Run HP-info to see if it gives the ink levels
$ hp-info
Or use this to only get the ink level (change the agent to get both black / color / …
I decided to unpack one and adding it to the setup path but still no joy.
EDIT 2: Managed to location the correct PPD by downloading the hplip locally, extracting and then copying the correct PPD across to the docker using docker cp. Now getting the following error after running hp-info:
warning: No display found.
error: hp-info -u/--gui requires Qt4 GUI support. Entering interactive mode.
error: No device found that support this feature.
i have a officejet 5740 which is support http://libinklevel.sourceforge.net/
whenever i run the command to test it im not getting back levels
ink -b bjnp://10.3.1.5
CRIT: udp_command: no data received (recv)CRIT: udp_command: no data received (recv)CRIT: udp_command: no data received (recv)Could not read from printer.
Could not get ink level.
I’ve already moved ink to its own directory as a result of 0.91, to /custom_components/ink . But, just updated to 0.92 and ink as a custom component is now broken.
I really liked the idea of your custom component, but as I use hassio I dont think it will work since ink needs to be installed in the homeassistant docker container.
So instead I took the approach to create a hassio addon that will run ink periodically, parse the output into JSON and sent it to HA via MQTT.
Its very much a hack job (esp the shell script that calls ink and mosquitto client for MQTT) but it works great for my Canon Pixma 5300, and supports HA MQTT autodiscovery - albeit in a very hard coded way
You can find it in my hassio addons repo:
To get other printers working you will probably need to edit the ink2mqtt.sh script.
Here is my lovelace card to show ink levels using the superb custom cards bar-card and vertical-stack-in-card:
It tried this but after starting the addon, I see this in the log:
/bin/ash: /ink2mqtt.sh: not found
It is not clear to me what I need to edit in the /config/ink2mqtt/ink2mqtt.sh file?
Actually, you have commented out the MQTT-code in the sh-file, so how is this supposed to work?
Hi @bouwew
Sorry for the delay to reply - Ive been away on vacation.
Looks like I screwed up when copying the addon from my local addons dir to github.
I have updated the ink2mqtt.sh file in the repo now. Please d/l the file and copy it to \config\ink2mqtt\ink2mqtt.sh
Thanks! Unfortunately, it is still not working.
I wonder whether the installation of the add-on is executed correctly on my system (hassio)?
For instance, the file /ink2mqtt.sh is not there after it placed the ink2mqtt.sh file from the repo in \config\ink2mqtt\ink2mqtt.sh and reinstalled the add-on. I also wonder whether ink is installed?
When I issue the command “ink” at the command-line, it says: “-bash: ink: command not found”.
Hi @bouwew
The ink executable is in the hassio addon’s container.
When you install the addon it runs all the commands in the dockerfile to download the source code for libinklevel and ink and then compile them.
(This is why it takes a long time to install the addon vs than with the precompiled images like most addons have)
I only tested the addon on x86 since my hassio is running on an intel architecture VM.
The install procedure should be:
Install the addon from my repo
Download/copy the ink2mqtt.sh file from the repo to /config/ink2mqtt (subfolder in the hassio config dir that you will need to make)
When the addon starts it will copy the ink2mqtt.sh from the config folder into the container. If you see in the dockerfile this is the final line.