Page 1 of 1

Sending number to 7 segment display

Posted: 16 Dec 2018, 19:06
by mackowiakp
I have two 4 digit MAX1637 based LED displays. On the first time is display correctly except not blinking colon. Now I want to send data to the second display. My question is. What is the proper command for sending data to the second display? I try something like this:
SendToHTTP 127.0.0.1,80,/control?cmd=7dn,22
But of course this command does not has specification of display name or display task number/name.

Can anybody help me to resolve the problem?

Re: Sending number to 7 segment display

Posted: 16 Dec 2018, 19:34
by grovkillen
Two displays on the same ESP?

Re: Sending number to 7 segment display

Posted: 16 Dec 2018, 19:39
by mackowiakp
Yes

Re: Sending number to 7 segment display

Posted: 16 Dec 2018, 19:52
by grovkillen
As far as I know the plugin officially only support one display per unit?

Re: Sending number to 7 segment display

Posted: 16 Dec 2018, 20:05
by mackowiakp
No such info in docu. The info is that it possible to def 12 sensors.

Re: Sending number to 7 segment display

Posted: 16 Dec 2018, 21:00
by grovkillen
Ok, generally only one display is supported. I haven't been at it yet, documentation is being added ASAP though.

Re: Sending number to 7 segment display

Posted: 19 Dec 2018, 11:23
by kimot
MAX1637 is Miniature, Low-Voltage, Precision Step-Down Controller
What about driving LED display with it ?!?

But if you mean some different LED display controller, this circuit obviously has got some "select" pins,
so drive them with other GPIO and use the same command for both disp.

Re: Sending number to 7 segment display

Posted: 19 Dec 2018, 11:40
by kimot
If you mean TM1637 instead of MAX1637,
switch CLK and DIO for both displays by multiplexer CMOS 4053 driven with some other gpio.
First switch to display you want and send normal command for display.

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 09:40
by mackowiakp
Yes, of course I mean TM1637 display driver. Sorry, my fault. Multiplexer is very good idea, I will try when buy such IC (or maybe You know about ready module?)
But at this moment I have physically connected only one such display to nodeMCU and only one display is defined in nodeMCU setup.
My goal it to multiplex two 4 digit 7 segment displays, one showing time and the second temperature from distant sensor. If temperature change, Domoticz will write new value to Dummy sensor in nodeMCU. The last thing works properly, it is possible to read distant temp value in "Device" section of nodeMCU WEB GUI.
The problem I have is that it is not possible to write any value to display from "inside" of nodeMCU using command like this (using "Command" option in "Tools" section of MCU but the "Result" window shows "OK")
SendToHTTP 127.0.0.1,80,/control?cmd=7dt,22
The display remains blank.
But it is possible to write it from Domoticz located in the same IP network segment. For test purposes I set nodeMCU "writable" for all IP address.
So what I am doing wrong? And how to display the time, with colon blinking in such configuration? Of course it is possible to write time each minute from Domoticz but it is not real solution in my meaning.

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 10:40
by kimot
And what about using rules?

Example

Code: Select all

On DSTemp#Temperature do
  7dt,[DSTemp#Temperature]
endon
But I have not this display for testing.

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 16:56
by mackowiakp
OK. Works. But how can I display a time? Remember that I have two muxed 4 digit 7 display unit. So I want to display right time by rule executed every round minute. Temp is written to separate display (after muxing by another GPIO) and display correctly and than switch again to time display.
I try to use rule command like this:
7dn,%syshour%.%sysmin%
But display simply dim completely. Any help?

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 17:17
by grovkillen

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 17:33
by mackowiakp
Mhhh. I did not find out such command in docu https://www.letscontrolit.com/wiki/inde ... _Reference. I can set time, run rule at spec time or use variables. Or - what is most possible - I miss something.
Please remember that I mux two displays to the same GPIO`s, first for display time and the second to display temp. So I can not to define one to display time only via WEB GUI. Just rule must write time as a numbers (each round minute).

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 18:15
by grovkillen
mackowiakp wrote: 20 Dec 2018, 17:33 Mhhh. I did not find out such command in docu https://www.letscontrolit.com/wiki/inde ... _Reference. I can set time, run rule at spec time or use variables. Or - what is most possible - I miss something.
Please remember that I mux two displays to the same GPIO`s, first for display time and the second to display temp. So I can not to define one to display time only via WEB GUI. Just rule must write time as a numbers (each round minute).
I see. Then it must be looked at.

The command list you linked to is the core commands. Plugin specific commands aren't part of that list. The new documentation on RTD (read the docs) will list them all.

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 18:35
by mackowiakp
Yep. I look to the source code and there is command "dst" not "dn". So proper, working syntax is:
7dst,%syshour%,%sysmin%
Problem solved. Be so kind to tell me is how can I run such command in rule at every day, hour, min and 00 sec. I did not found out is the second resolution avaliable in Clock#Time= command or not.

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 18:42
by grovkillen

Code: Select all

On Clock#Time=All,**:** Do
 7dst,%syshour%,%sysmin%
EndOn

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 18:58
by mackowiakp
THX. Problem solved. Excenpt not blinking colon on time display. THX once more

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 19:02
by grovkillen
mackowiakp wrote: 20 Dec 2018, 18:58 THX. Problem solved. Excenpt not blinking colon on time display. THX once more
Might be able to ask the maintainer (open a new issue on GitHub) to add a command for colon on/off. That could then be triggered once per second, 7dc,1 for on and 7dc,0 for off.

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 19:09
by mackowiakp
OK. THX !

Re: Sending number to 7 segment display

Posted: 20 Dec 2018, 21:00
by mackowiakp
kimot wrote: 19 Dec 2018, 11:40 If you mean TM1637 instead of MAX1637,
switch CLK and DIO for both displays by multiplexer CMOS 4053 driven with some other gpio.
First switch to display you want and send normal command for display.
Is it necesery to switch both CLK and DIO inputs or switching only DIO in enough ? CLK inputs solder together of course.

Re: Sending number to 7 segment display

Posted: 25 Jul 2019, 20:15
by LanWolf
Hello, it seems that mega-20181122 breaks 7 segement support ? on mega-20181121 i have it functioning okay, but updating to later versions break the display.

Re: Sending number to 7 segment display

Posted: 25 Jul 2019, 23:30
by grovkillen
Have you updated the settings by re-submit the settings? With that I mean make sure you go into the task/device and hit submit.