Closed royf007 closed 3 months ago
@samuelspagl , sure, no problem at all to adjust the description!
Hello everyone! π
A new Beta of the integration comes fresh out of my development oven. π While I understand the frustration of lacking entities for custom capabilities, Iβve made some improvements to enhance your experience and added service calls for:
And thatβs not all! Iβve also fixed and added some essential controls:
Link to the beta release (And yeah, I know that I need to make a nicer description π€) Remember, this is a beta version, so your feedback is invaluable. Letβs make our soundbar experience even better! π
Wishing you all a fantastic start into the weekend! π
Hello @samuelspagl ! Thank you for doing this. I will be playing with the new Beta release. I like how you implemented the new configuration flow. I was able to add the problematic "Living Room" soundbar and used the "Woofer number" capability only in order to have the setup complete:
Cheers, and have a great weekend!
I'm exactly on the same page as royf007, finally I'm able to config the soundbar but only woofer extra capability.
Then I try adding a "new hub" with same device_Id and it worked with the other 3 capabilities that where giving me problems earlier
Interesting, so you enabled things like "soundmode" again in the other "hub" right? but still, the select
entity should not be populated, and there should still be errors in the log, right?
Maybe I should add a validation for those "extra capabilities".
@samuelspagl I got it "all working" with no error log. Let me explain what I did:
As I said, there's no error log for any interaction with this entities.
Cheers
@cristhianerg Good suggestion there your method worked better than mine mine was a bit forceful, as for the sound modes I guess @samuelspagl was trying to be mindful in case the API does come back so looking at the code although I can't say with certainty, I think it does try to retrieve the sound modes, I have modified that part of the code and I can say with 100% confidence it works instantly to change the sound mode, it does work a bit like "IR Setup" since it's one way but that's only if you do not use the Smartthings app which I'd rather not guess that's the case for everyone who's here, although there's a small caveat you cannot change the sound mode from the "select" directly you have to call it by service, I have not found a service for the EQ to confirm that one as well, but oh boy let's just say the Sound mode change Is instant same goes for Woofer as well, hope that helps everyone with the sound mode until @samuelspagl can work within the constraints and "limitations" SmartThings brings to us for our own Safety along with the many CVE's this soundbar brings, cheers to @samuelspagl for justice it brings to our soundbars as this is the last one I'll buy from Samsung π
PS I've enabled Bass and Voice mode as they do reset to 0 when home assistant restarts and I keep them on most of time enabled so that's not essential. same goes for "Active Sound mode" as well.
So I've made some changes to the code, no longer needed to add multiple soundbars and it will keep in mind if the API ever comes back to normal, now the first piece of code needed to be modified is this, add your supported sound modes, same goes for EQ as well although It doesn't work for me,
Now we modify this part of the code here
Into this, this part here ensures that you can add a single soundbar without the need of multiple ones, it will also keep in mind when the API ever comes back to update itself.
Further more on Sound mode, this is not required but it does make it easier to see what sound mode, basically instead of trying to get the sound mode selected from the API it will use the sound mode selected from the "select" entity, this part of the code needs to be changed if you want to reflect the changes immediately into the media player.
To this, do note that I've introduced "__selected_soundmode" which is defined here "self.__selected_soundmode = None" this is the part of the code that ensures it reflects the sound mode selected without the need of API, but if the API comes back online it will get updated automatically anyway, now this should work without the need of multiple soundbars and it works pretty well, the EQ I haven't managed to get it working but at this point I am happy to have this which is really really good specially the woofer levels.
I've also made a script on Home Assistant for more easier automations for anyone who's interested
From the looks of it SmartThings team will take some years before they respond, the changes I've shared here makes the soundbar functional again, although it's "one way" anything you change to will make it seem like it "update itself", so for now although EQ doesn't work for me, I didn't use it that much to begin with, I guess this should do it for me, thanks again @samuelspagl for the hard work.
Peace.
@Coinficient Yeah I didn't do the EQ service yet ππ I simply forgot about it π I'll add it in a few days
PS I've enabled Bass and Voice mode as they do reset to 0 when home assistant restarts and I keep them on most of time enabled so that's not essential. same goes for "Active Sound mode" as well.
Fine if you change it for you, but as Soundmode "may" be changed by Samsung at some point or differ from soundbar to soundbar, I will not add something like this to the main codebase ^^ jfyi
@Coinficient I added some
@samuelspagl Thank you for that, believe it or not I am still new to Github when it comes to exchanging information π, as for the sound mode code, of course it was meant to be more as a guide for people to get it working until you find a more efficient solution, in fact the whole code I shared was more as a guide rather than a direct implementation, for now this works good on my side until you find a more balanced option.
I will close this issue with the merge of #28. Additionally I will create a new Issue, pin that one, and keep it open for the future. I still hope, that at some point things get back to normal again.
Hello @samuelspagl , I have managed to successfully configure the device (Samsung Soundbar S61B) using this method https://github.com/samuelspagl/ha_samsung_soundbar/issues/26#issuecomment-2041027513
The problem is that if I restart the homeassistant container the EQ and soundmode and also the Advanced audio switches go into Failed to setup: check logs
If I reconfigure them in the correct order from the method above it is working again but after every restart it goes in the same error state.
Can this be fixed somehow? Or is there anything I can do to mitigate this? I am mostly interested in automating turning on/off Night Mode.
I'm using the latest version 0.4.0
Thank you!
So, I have been using this great integration with no issues on 2 Samsung Q990C soundbars for a few weeks.
I recently bought a 3rd Q990C. It's on the same network, same firmware version as the other 2. I'm able to use the Yamaha MusicCast API (api.smartthings.com) through Postman, obtain the device ID, send commands, etc. I'm also able to see it in the SmartThings integration in Home Assistant.
When I go to try to add the 3rd soundbar to this integration as a new "hub", it always fails to configure. I've even tried to remove and add back the other 2 soundbars that were previously working, and there are no issues adding them back.
I'm not really sure why I can't add this 3rd soundbar.
Any help would be appreciated. Here is the log entry:
Log Entry
``` Logger: homeassistant.config_entries Source: config_entries.py:504 First occurred: 12:13:07 AM (4 occurrences) Last logged: 12:15:29 AM Error setting up entry samsung_soundbar for samsung_soundbar Error setting up entry Living Room Soundbar for samsung_soundbar Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/config_entries.py", line 504, in async_setup result = await component.async_setup_entry(hass, self) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/samsung_soundbar/__init__.py", line 52, in async_setup_entry await soundbar_device.update() File "/config/custom_components/samsung_soundbar/api_extension/SoundbarDevice.py", line 52, in update await self._update_soundmode() File "/config/custom_components/samsung_soundbar/api_extension/SoundbarDevice.py", line 74, in _update_soundmode payload = await self.get_execute_status() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/samsung_soundbar/api_extension/SoundbarDevice.py", line 390, in get_execute_status return dict["data"]["value"]["payload"] ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^ TypeError: 'NoneType' object is not subscriptable ```