Skip to content
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

Application.MP3 #183

Open
sebirdman opened this issue Oct 21, 2021 · 2 comments
Open

Application.MP3 #183

sebirdman opened this issue Oct 21, 2021 · 2 comments
Labels
no-stale usage question How to use the library

Comments

@sebirdman
Copy link

Hi!

I'm in the process of adding support for my "MP3" device which includes some sleep/lullaby tones for baby.

I've got a pretty good idea about how to add the command structure to change the volume. However, my biggest struggle is when determining the initial state of the device. Currently this library does:

        result = await self._execute_command(method="GET",
                                             namespace=Namespace.SYSTEM_ALL,
                                             payload={},
                                             skip_rate_limits=skip_rate_limits,
                                             drop_on_overquota=drop_on_overquota,
                                             timeout=timeout)

which of course, feels like it should get the WHOLE state for the device. This doesn't appear to be correct because the audio state isn't there. I have to do:

        result = await self._execute_command(method="GET",
                                             namespace=Namespace.CONTROL_MP3,
                                             payload={},
                                             skip_rate_limits=skip_rate_limits,
                                             drop_on_overquota=drop_on_overquota,
                                             timeout=timeout)

Any ideas on how i can avoid the extra call? Otherwise, it feels like as soon as the Namespace.CONTROL_MP3 feature is detected, we will have to make a separate call somehow.

Thanks so much for this library! The light part of my device "just worked" in home assistant.

@stale
Copy link

stale bot commented Dec 20, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 20, 2021
@stale stale bot closed this as completed Dec 27, 2021
@albertogeniola albertogeniola added usage question How to use the library no-stale and removed stale labels Oct 8, 2022
@albertogeniola albertogeniola reopened this Oct 8, 2022
@albertogeniola
Copy link
Owner

Hi @sebirdman ,
sorry for the late reply. In order to add an MP3 mixin, I need to gather more information about the device itself and the way it works.

To help me implement this feature in a dedicated mixin, I need you to:

  1. Provide the specific meross device name (i.e. mss310, mse425, etc);
  2. Provide the constant value of Namespace.CONTROL_MP3;
  3. Provide the result of the GET call to Namespace.CONTROL_MP3
  4. Provide an example of a PUSH notification received by the app when someone changes the tone on the device (you can use the meross sniffer for that)
  5. Provide an example (if supported) of a command to change tone on the device

I usually gather that info by myself when I do own a device to use; unfortunately I have no such device implementing the MP3 capability, so I cannot help on this one.

Let me know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-stale usage question How to use the library
Projects
None yet
Development

No branches or pull requests

2 participants