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

Support presets in MiLight app #31

Closed
itProfi opened this issue Apr 3, 2017 · 44 comments
Closed

Support presets in MiLight app #31

itProfi opened this issue Apr 3, 2017 · 44 comments
Milestone

Comments

@itProfi
Copy link

itProfi commented Apr 3, 2017

It's normally, that saved value in Milight app do not apply ?
photo_2017-04-03_20-27-37

@itProfi itProfi changed the title Milight app v3 some qustion Milight app v3 some question Apr 3, 2017
@itProfi itProfi changed the title Milight app v3 some question Milight app v3 some bugs.. Apr 4, 2017
@itProfi
Copy link
Author

itProfi commented Apr 4, 2017

photo_2017-04-04_20-44-53
When i choose this remote control (virtual FUT091), which we test in Web interface, it dont work with my FUT035 controller, and i see in debug:
:ON:
session: 0002, sequence: 229, group: 1, checksum: 60
Command cmdType: 31, cmdHeader: 00000304, cmdArg: 03000000
V6MiLightUdpServer - Unhandled command: 31 00 00 03 04 03 00 00
[MiLightUdpServer port 5987] - Handling packet: 80 00 00 00 11 00 02 4C E6 00 31 00 00 03 04 04 00 00 00 01 00 3D
Packet size: 22
:OFF:
session: 0002, sequence: 230, group: 1, checksum: 61
Command cmdType: 31, cmdHeader: 00000304, cmdArg: 04000000
V6MiLightUdpServer - Unhandled command: 31 00 00 03 04 04 00 00
[MiLightUdpServer port 5987] - Handling packet: 10 00 00 00 0A 02 AD A7 11 18 FE 34 D3 95 31
But, when i choose this remote control:
photo_2017-04-04_20-55-03
all works OK.

@sidoh
Copy link
Owner

sidoh commented Apr 4, 2017

Right, I don't think that remote is handled right now. Do you need it?

@itProfi
Copy link
Author

itProfi commented Apr 4, 2017

photo_2017-04-04_20-44-53
FUT091 - we begin our work together with him :) Please, can you add this remote in UDP code?

@sidoh
Copy link
Owner

sidoh commented Apr 4, 2017

Yeah, should be straightforward enough. There are some other things I want to get to first, though (namely wrapping up the LT8900 stuff)

@itProfi
Copy link
Author

itProfi commented Apr 4, 2017

Ok, wait..Thanks!

@itProfi
Copy link
Author

itProfi commented Apr 4, 2017

Whats about
"It's normally, that saved value in Milight app do not apply ?"
585af158-18ac-11e7-9540-45f8f5104f29

@sidoh
Copy link
Owner

sidoh commented Apr 4, 2017

Yep, I'll take a look when I finish up the other stuff =)

@itProfi
Copy link
Author

itProfi commented Apr 4, 2017

Thanks!

@itProfi
Copy link
Author

itProfi commented Apr 4, 2017

Do you know, how mute sound in app v3 :)?

@sidoh
Copy link
Owner

sidoh commented Apr 4, 2017

lol never noticed there is sound

@itProfi
Copy link
Author

itProfi commented Apr 4, 2017

I mean sound, when rotate the wheel with brightness, for example..

@sidoh
Copy link
Owner

sidoh commented Apr 5, 2017

I don't think mine has sound lol :)

re: saved modes, this is yet another undocumented feature of the protocol. Just took a crack at implementing it. Can you try the udp_presets branch?

@itProfi
Copy link
Author

itProfi commented Apr 5, 2017

When i try udp_preset branch i receive:
Compiling .pioenvs\esp12\src\main.o
Archiving .pioenvs\esp12\libFrameworkArduinoVariant.a
xtensa-lx106-elf-g++: error: unrecognized command line option '--always)"'
xtensa-lx106-elf-g++: fatal error: no input files
compilation terminated.
Compiling .pioenvs\esp12\FrameworkArduino\Esp.o
Compiling .pioenvs\esp12\FrameworkArduino\FS.o

Compiling .pioenvs\esp12\FrameworkArduino\HardwareSerial.o
xtensa-lx106-elf-g++: error: unrecognized command line option '--always)"'
xtensa-lx106-elf-g++: fatal error: no input files
compilation terminated.
Compiling .pioenvs\esp12\FrameworkArduino\IPAddress.o
xtensa-lx106-elf-g++: error: unrecognized command line option '--always)"'
xtensa-lx106-elf-g++: fatal error: no input files
compilation terminated.
Compiling .pioenvs\esp12\FrameworkArduino\MD5Builder.o
xtensa-lx106-elf-g++: error: unrecognized command line option '--always)"'
xtensa-lx106-elf-g++: fatal error: no input files
compilation terminated.
Compiling .pioenvs\esp12\FrameworkArduino\Print.o
xtensa-lx106-elf-g++: error: unrecognized command line option '--always)"'
xtensa-lx106-elf-g++: fatal error: no input files
compilation terminated.
*** [.pioenvs\esp12\src\main.o] Error 1
*** [.pioenvs\esp12\FrameworkArduino\Esp.o] Error 1
*** [.pioenvs\esp12\FrameworkArduino\FS.o] Error 1
:(((
But, when i use this file from branch "esp8266_milight_hub-1.2.0" - build OK

@sidoh
Copy link
Owner

sidoh commented Apr 5, 2017

I think I wasn't being very clear about what's broken.

It's just platformio.ini. If you replace it with the version from 1.1.0 it should work just fine.

@itProfi itProfi changed the title Milight app v3 some bugs.. Milight app v3 some futures.. Apr 5, 2017
@itProfi
Copy link
Author

itProfi commented Apr 5, 2017

udp_presets branch works correctly!

@itProfi
Copy link
Author

itProfi commented Apr 5, 2017

Some little bug: when we long press ON button, we see in debug: V6MiLightUdpServer - Unhandled command: 31 00 00 08 84 01 00 00 - i think is command Light ON on 100%
When i sniff FUT091 i see:
Packet received (9 bytes):
Raw packet: C8 14 2A 1C 1E 08 4F 9D C8

Decoded:
Key : C8
b1 : 21
ID : 1141
Command : 81
Argument : 00
Sequence : A5
Group : 00
Checksum : 89
Packet received (9 bytes):
Raw packet: 79 3D F7 DD C1 21 73 43 F9

Decoded:
Key : 79
b1 : 21
ID : 1141
Command : 81
Argument : 00
Sequence : A4
Group : 00
Checksum : D9
Packet received (9 bytes):
Raw packet: DF 0C 91 FB 03 62 74 98 1F

Decoded:
Key : DF
b1 : 21
ID : 1141
Command : 81
Argument : 00
Sequence : A3
Group : 00
Checksum : 2A

@itProfi itProfi changed the title Milight app v3 some futures.. Milight app v3 some features.. Apr 5, 2017
@sidoh
Copy link
Owner

sidoh commented Apr 5, 2017

Nice.

Makes sense, I can poke at that later today.

@sidoh sidoh added this to the 1.2.0 milestone Apr 6, 2017
@sidoh
Copy link
Owner

sidoh commented Apr 6, 2017

So I don't think this behavior for FUT092. Holding down on or off doesn't seem to do anything.

Can you remind me what bulbs you're using with FUT091?

@itProfi
Copy link
Author

itProfi commented Apr 6, 2017

I use FUT035 LED strip controllers - http://futlight.com/productdetails.aspx?id=124&typeid=146
When holding down ON - command for FULL brightness, holding down off - NIGHT MODE (about 2-4 % brightness).
BTW - Futlight released new remot control - 8 zone - http://futlight.com/productdetails.aspx?id=278&typeid=143
Maybe with new protocols command:)
From my Chinise supplier:
"they are texting this product , to make sure everything is ok . if it is ok to buy at the end of this month ,i will tell u"

@sidoh
Copy link
Owner

sidoh commented Apr 6, 2017

Oh ok. Those are controlled by the RGB radio right?

I think there's an 8 zone controller in the v6 wifi box. I poked at the protocol and it looks pretty similar to the protocol for FUT092. Just different offsets in on/off commands to accommodate more groups.

@itProfi
Copy link
Author

itProfi commented Apr 6, 2017

Oh ok. Those are controlled by the RGB radio right?
What you mean?

I use FUT035 LED strip controllers (CCT2 not RGB) - http://futlight.com/productdetails.aspx?id=124&typeid=146
When holding down ON (on FUT091) - command for FULL brightness, holding down off - NIGHT MODE (about 2-4 % brightness).

@sidoh
Copy link
Owner

sidoh commented Apr 6, 2017

Which mode in esp8266_milight_gateway do you use to control these devices?

@itProfi
Copy link
Author

itProfi commented Apr 6, 2017

I mean in Milight app v3 i use 1st remote control (RGG+CCT) - it's has separate button - Night mode, but don't have mode Full brighness, wich work (on LED controller), when i holding down ON button on real FUT091...

@sidoh
Copy link
Owner

sidoh commented Apr 6, 2017

Gotcha. It's interesting that these worth with FUT091/FUT092 at all. Neither of them are listed as compatible on FUT035's product page (the one you linked). It says it's compatible with FUT005, FUT006, and FUT007.

@itProfi
Copy link
Author

itProfi commented Apr 6, 2017

Yes, you are right. But if we see on http://futlight.com/productdetails.aspx?id=233&typeid=100 (FUT091) we see compatible LED controller (FUT035, FUT036 and it's on fact and another different bulbs). I think desription on FUT035 not full..

@sidoh
Copy link
Owner

sidoh commented Apr 6, 2017

I see, makes sense.

Can you give the held_commands branch a try? Basically I tried to make it so that if you hold a button in the app, that's reflected in the RF packets. Haven't had a chance to test it out myself.

@itProfi
Copy link
Author

itProfi commented Apr 6, 2017

Yes, it's work! Thanks!

@sidoh
Copy link
Owner

sidoh commented Apr 6, 2017

Sweet. I'll merge into 1.2.0 later.

@sidoh
Copy link
Owner

sidoh commented Apr 7, 2017

Thanks as always for finding bugs and providing suggestions, @Lstt2005!

Does that cover it for this ticket? Anything else you had in mind?

@itProfi
Copy link
Author

itProfi commented Apr 7, 2017

Can you plane support FUT091 in Milight App? :)

@sidoh
Copy link
Owner

sidoh commented Apr 7, 2017

Oh, right. Can certainly look into it.

Are there things this remote does that FUT092 doesn't? It's pretty easy to add support, just don't wanna add bloat :)

@itProfi
Copy link
Author

itProfi commented Apr 7, 2017

No, there certainly are no additional functions .. Just when you select multiple WiFiBox, it's more convenient to click on its icon, and then the only CCTv2 mode control tab will open immediately. A trifle, but very convenient, when the number of management points (Wifi) is large .. :)
If you can invented for support multiple gateways in MiLIght app V3 (in tabs of gateways) works with one ESP It's WILL BE MIRACLE!

@sidoh
Copy link
Owner

sidoh commented Apr 7, 2017

So I poked at this again for a bit, and I'm now at least pretty convinced it's possible, but it'll take some fairly significant changes to the way UDP packets are handled.

Basically rather than varying the port, I think you could have a UDP server with multiple device IDs respond with several different MAC addresses. Both the discovery packet response and the session start request have a MAC address in them, so you should know which device the client is trying to address.

It'll take a bit of time, but should be doable.

@itProfi
Copy link
Author

itProfi commented Apr 7, 2017

UDP server with multiple device IDs

You mean C++ code inside you library on external server?

@sidoh
Copy link
Owner

sidoh commented Apr 7, 2017

Inside the C++ code.

The result, if it works like I'm hoping it will, is that you'd see a bunch of devices show up in the device list, each responding to commands with a different device ID.

@itProfi
Copy link
Author

itProfi commented Apr 7, 2017

It would be just amazing !!!!!
BTW, yesterday - the day before yesterday Milight v3 was updated on GooglePlay.

@sidoh
Copy link
Owner

sidoh commented Apr 7, 2017

Sweet. Anything new?

@itProfi
Copy link
Author

itProfi commented Apr 7, 2017

Write:1.Modified some bugs to be compatible with some smartphone which cannot work before.
Visually nothing change.

The result, if it works like I'm hoping it will, is that you'd see a bunch of devices show up in the device list, each responding to commands with a different device ID.

It would be possible to manually set the device names in list, like as : kitchen, dinig room, etc? Maybe in code directly?

@sidoh
Copy link
Owner

sidoh commented Apr 7, 2017

Probably not unless the Milight app has support for it.

@itProfi
Copy link
Author

itProfi commented Apr 7, 2017

It turns out that this can be changed in the application:
photo_2017-04-07_20-40-24

@sidoh
Copy link
Owner

sidoh commented Apr 7, 2017

Ah, sweet! Where is that screen?

@sidoh
Copy link
Owner

sidoh commented Apr 7, 2017

Oh i see it. You left-swipe on the line item and an edit button shows up. Pretty well hidden haha

@sidoh
Copy link
Owner

sidoh commented Apr 9, 2017

edit - gonna move this to the other ticket you opened.

@itProfi
Copy link
Author

itProfi commented Apr 9, 2017

ok. i see.

@sidoh sidoh changed the title Milight app v3 some features.. Support presets in MiLight app Apr 16, 2017
@sidoh sidoh closed this as completed Apr 22, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants