Componente camera

hi everyone, i have dhua cameras, i wanted to implement them on hassio, i put in my configuration.yaml file:
‘’’
stream:

camera:

  • platform: generic

still_image_url: “http://mioip/cgi-bin/snapshot.cgi

stream_source: “rtsp://username:apssword@miip:554/cam/realmonitor?channel=1&subtype=00”

username: username

password: password
‘’’
but when i try to verify the configuration it gives me this error:

Platform error camera.template - No module named 'homeassistant.components.template.camera

Please try again to format the YAML code from configuration.yaml so that we can read it properly.

But from what I can see I don’t think that error is due to what you posted. Are you sure there isn’t something like the following somewhere in your configuration?

camera:
  - platform: template

Note that some Dahua cameras work well with the amcrest integration. You may want to give it a try.

Yes, now i move the block code camera on top of my configurazione.yaml and now work. But i have another problem. I would see live stream but not work, i try Two method:

vere i dont see nothing only inactive label***
- type: picture-entity
entity: camera.nomecamera
camera_view: live

here i see only last picture not live***************
- type: picture-elements
image: https://i.imgur.com/FHZLxXp.png
elements:
- type: image
camera_image: camera.nomecamera
camera_view: live
style:
left: 50%
top: 50%
width: 100%
height: 100%

How can i Fix ? Are there setting into my dvr?

Follow the link and you will see it specifies that you must setup your camera encoding to H.264
Once I did that my cameras are working in HA. https://dahuawiki.com/Remote_Access/RTSP_via_VLC

My Config:

 - platform: generic
    still_image_url: http://username:[email protected]/cgi-bin/snapshot.cgi?channel=1
    stream_source: rtsp://username:[email protected]:554/cam/realmonitor?channel=1&subtype=1
    username: username
    password: password
    authentication: digest
    verify_ssl: false
    name: Gate - Main Inside