New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Axis Camera Integration needs a refresh #89967
Comments
Hey there @Kane610, mind taking a look at this issue as it has been labeled with an integration ( Code owner commandsCode owners of
(message by CodeOwnersMention) axis documentation |
Thanks for reporting. What button are you using for snapshot? Or is it a service you're calling? Suggestions of new features are best put here https://github.com/Kane610/axis |
I'm using various angles in home assistant. I have several m3116-lve's and those work like a champ. A way I can test this outside of the automation is to create a picture glance card, and in the dialog to configure the card, there are 'auto' and 'live' radio buttons. Auto creates a still image. Live creates a video feed. the m3116-lve's will do both, no problems, but the m3206-lve will only do video, no still images. I've also opened a ticket with axis as well (I have fifteen cameras) asking for clarity, and an updated API reference document, so I'll reply here when I get any interesting data out of them. Amusingly, the newest camera I have, the m3077-plve (synology doesnt even know about this one yet!) seems to work just fine, and its one of those fisheye cameras. In the meantime - if there's something you'd like me to test I'm happy to go under the hood! |
I see your other repo was updated just days ago - is there a way to import that newest version of the axis integration into my hassos/rpi setup to get the newest version? |
There are no relevant changes, I'm preparing some refactoring of the library together with some dependency bumps. The integration is in need of some improved structuring so I'm investigating that currently. |
I found part of the issue, check it out. Would you consider either testing a few different URI strings to make sure they're valid, or letting the user input their own URI for the camera, if its being persnicketty like this one? |
Are you running the latest firmware on all those devices? There should be some logics behind how to compile the URI where I've probably missed something small difference with the m3206 |
Dont know if its related.. But I have a M3106LVE with latest firmware 9.80.2.2 |
Hello I was looking at the integration code, have you perhaps configured the options of the integration? Can you check in your home-assistant/.storage/core.config_entries what the contents of the options of the integration is? Since it's adding camera it should not be empty. So it might be possible to resolve without patching the integration :) |
Different issue |
I checked that file and it definitely looks like there's content in it.
I can see an entry for the camera.
On 2023-04-24 10:51, Robert Svensson wrote:
Hello
I was looking at the integration code, have you perhaps configured the
options of the integration?
Can you check in your home-assistant/.storage/core.config_entries what
the contents of the options of the integration is?
Since it's adding camera it should not be empty. So it might be
possible to resolve without patching the integration :)
--
Reply to this email directly, view it on GitHub [1], or unsubscribe
[2].
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
I have some more information about this issue. It seems that something home assistant is doing to the camera is causing it to 'become broken'. can you give me an idea of how the axis integration tries to communicate with the camera before it tries to fetch an image? i've also concurrently opened a support request with axis to see if they can help |
Can you share the content of the config_entry for the axis camera? It should look something like {
"entry_id": "aade4617cda4bb79a3482f301bcdd8aa",
"version": 3,
"domain": "axis",
"title": "M3106-LVE - ACCC8E000000",
"data": {
"host": "192.168.0.13",
"port": 80,
"username": "root",
"password": "pass",
"model": "M3106-LVE",
"name": "M3106-LVE 0"
},
"options": {
"stream_profile": "No stream profile",
"video_source": 1
},
"pref_disable_new_entities": false,
"pref_disable_polling": false,
"source": "ssdp",
"unique_id": "ac:cc:8e:00:00:00",
} what you want to try in your case is to change the options to not contain the "video_source" part, make sure to remove the "options": {
"stream_profile": "No stream profile"
}, Hopefully this works. |
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. |
this issue has not been resolved by any of the subsequent home assitant updates. It has to do with the specific URI used to query axis cameras, and since that remains unchanged, the issue remains. Some of the newer firmwares for axis cameras can be a little persnicketty, and in the case of the issue I'm trying to resolve, it seems that one or two additional requests need to be made in order to get the camera to behave properly. |
Start by following #89967 (comment) and see if that helps |
There's the entry in full! i removed the 'video_source' line per your instructions, and rebooted home assistant, but this has not resolved the issue. |
Just to clarify; you tried streams with and without |
It works in synology surveillance station, but I can't get it to work in tinycam at all, and with curl I get the same results as above, even with new firmware. I've opened a ticket with axis for help as well |
I think i figured it out. I flashed the camera with fresh firmware and when i hit the 'rotate 180 degrees' option because the picture is upside down, suddenly home assistant breaks. It has something to do with the api. when i curl before i flip the image, it works fine. but after i flip the image it breaks. so this seems like its entirely an axis bug. |
For my own reference should I want to try it myself, you mean after the integration is up and running with video and events you change the video to be rotated 180 degree and the integration then fails and requires a restart? Or it also affects just retrieving a snapshot? |
This camera is hung with a commercial setup over my driveway, and the home asstant integration, for a very long time, worked just fine, no worries. Then one day the camera 'just stopped showing up in home assistant', so I started to investigate. what i discovered was that it 'worked sometimes'. From first boot, its fine if you try to curl the api - but the second you aim home assistant at it "it breaks". I'm not 100% what the actual request is that HA makes that causes a change in the camera, but in theory, curling the api shouldnt 'write anything' or make any modifications. I started a conversation with axis support and twice (over several months) I basically stumped the support person trying to help. Today, I did a full factory reset and firmware flash, and noticed that HA seemed to like the camera until I flipped the image. Having noticed that I decided 'maybe if I just go unscrew the camera and rotate the camera element itself, I wont have to use software to flip the picture, and that may get around the issue' - when I took the camera apart some dead bugs fell out of it (which is bad. bugs arent supposed to be able to get inside it) - and now I'm beginning to think there is some kind of physical problem and the bizarro api behavior is just a symptom. I took the camera down from its mount and I'm going to begin the RMA process - but sadly this leaves questions unanswered. A good troubleshooting step if you would like to try this yourself, is to login to an axis camera yourself, and flip the picture in the image settings, and see if HA has a seizure. It seems to ONLY affect this camera - and it "just started happening one day", and i had attributed that to an HA upgrade, since I upgraded HA and this problem happened at the same time. hopefully you get somewhere with your troubleshooting. hopefully axis will let me RMA this thing. |
I have an update from axis! if i make the request If there's a way to manually specify a resolution for this camera, this will temporarily solve the issue and it'll work in home assistant again until axis hq in sweden fixes the underlying bug. |
I've tried adding a 'resolution' section in the config_entry file, and ive even created a stream profile that forces the resolution down to 1280x960 - but it seems home assistant refuses to allow for me to specify the resolution for 'any image requests' - now i can get the camera to stream video, and that works, but HA still can't get still images out of it, so the thumbnail for the camera is empty, and none of the image/snapshot autonations can get an image out. at least in the short term, if theres a way to specify "a global resolution to use for any requests made to the camera, for anything" tnat would solve the problem. |
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. |
The problem
Newer axis cameras that get newer firmware have slight changes in the API that the current integration doesn't account for, so certain things (like camera.snapshot) do not work. In this case, it's a camera on new firmware and for some reason the 'default' axis URI path to fetch images and video doesn't work for this camera.
What version of Home Assistant Core has the issue?
2023.3.5
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant OS
Integration causing the issue
axis
Link to integration documentation on our website
https://www.home-assistant.io/integrations/axis
Diagnostics information
for some reason this camera is throwing errors when attempting to grab a snapshot, but works just fine when viewing the camera stream. I'm happy to open a ticket with axis to get their input, but I'm betting what's going to happen is that they'll say there's a slightly different URI needed for this model of camera, and those updates will need to go into the integration.
I'm happy to do testing and work with folks to get this sorted out!
Example YAML snippet
No response
Anything in the logs that might be useful for us?
I have a BUNCH of axis cameras, so if we wanna go over those to make sure the integration can pick up all the cool sensors and stuff these things can do (theres a lot) I'm game to help! At some point recently the axis integration 'just stopped being able to gather these details' - it used to work and then 'just stopped' - not sure why. I wager going back and looting the older version of this integration for those details would be super helpful
The text was updated successfully, but these errors were encountered: