calaos / calaos_base Goto Github PK
View Code? Open in Web Editor NEWCalaos server
Home Page: https://calaos.fr
License: GNU General Public License v3.0
Calaos server
Home Page: https://calaos.fr
License: GNU General Public License v3.0
After startup, all Wago digital inputs are considered false into calaosd, whatever their actual state.
If an initially true input value switches for the first time to false, it is not reported and none of the relevant rules is triggered.
As a conclusion a Wago digital input value in calaosd isn't reliable until it has become true once since last calaosd startup.
The input Scenario is not reset to 0 after 250ms like all InputSwitch does.
For now, impulse action is only available for the "light" output type.
We need to add the same command (simple impulse, impulse with pattern) to all true/false IO like "light_dimmer", "light_rgb", "var_bool".
Maybe also for "analog_out"?
All output must use the name Switch instead of the current name Light for outputs, sometimes on/off outputs are not a light, it's the case for example for heating system.
The harmony ultimate is connected to the internet by using a wifi connection on the hub. The protocol has been reversed, and is available here:
https://github.com/jterrace/pyharmony/
Today, for heating, it's only possible to use "light variable" for On-Off solenoid valve.
By click on existing scenario "turn off all lights", the system turn off too the solenoid valves...
A other symbol could be created too.
Load and save config files from JSON api. Add that once the json api will be in calaos_server. It allows calaos_installer to load/save config files directly from calaos_server and calaos_server can reload immediatly without restarting.
The Debian build dependencies contain libvmime-dev, however this package doesn't exist in Wheezy (it existed in Squeeze and is still in Sid, but it is absent from Jessie too)...
vmime is used in SendMail.cpp and in JsonApiClient.cpp.
Is there a solution for Wheezy ?
Remove log4cpp and use eina_log instead.
log4cpp adds another dependency wich can be removed by using the standard mechanisms present in EFL.
With latest commit (01.14.2014), Calaos Home doesn't display the I/O states and set-point values...(OK with calaos web)
make all-recursive
make[1]:
Entering directory /home/maison/calaos_base' Making all in src make[2]: Entering directory
/home/maison/calaos_base/src'
Making all in lib
make[3]:
Entering directory /home/maison/calaos_base/src/lib' make[3]: Nothing to be done for
all'.
make[3]: Leaving directory /home/maison/calaos_base/src/lib' Making all in bin make[3]: Entering directory
/home/maison/calaos_base/src/bin'
Making all in calaos_server
make[4]: Entering directory /home/maison/calaos_base/src/bin/calaos_server' CXX main.o CXX IO/InputTime.o IO/InputTime.cpp:29:1: error: call of overloaded ‘Registrar(const char [10], <lambda(Params&)>)’ is ambiguous IO/InputTime.cpp:29:1: note: candidates are: In file included from ./ListeRoom.h:39:0, from ./ListeRule.h:31, from IO/InputTime.cpp:23: ./IO/IOFactory.h:39:5: note: Calaos::Registrar::Registrar(std::string,std::function<Calaos::IPCam*(Params&)>) ./IO/IOFactory.h:38:5: note: Calaos::Registrar::Registrar(std::string,std::function<Calaos::AudioPlayer(Params&)>) ./IO/IOFactory.h:37:5: note: Calaos::Registrar::Registrar(std::string,std::function<Calaos::Output*(Params&)>) ./IO/IOFactory.h:36:5: note: Calaos::Registrar::Registrar(std::string, std::function<Calaos::Input*(Params&)>) make[4]: *** [IO/InputTime.o] Error 1 make[4]: Leaving directory
/home/maison/calaos_base/src/bin/calaos_server'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory /home/maison/calaos_base/src/bin' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory
/home/maison/calaos_base/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/maison/calaos_base'
make: *** [all] Error 2
Add a parameter to IO called "style". It can then be used to display IO differently from their kind like:
style="gauge" can display value in gauge style
style="default"
when using WebInputAnalog as an input with
<calaos:input coeff_a="0" coeff_b="1" file_type="json" frequency="100000" id="input_69" max="10000" min="-10000" name="pluie 1" path="rain/1h" step="1" type="WebInputAnalog" unit="mm / 1h" url="http://api.openweathermap.org/data/2.5/weather?q=paris"/>
the input is not updating, only after a server restart it picks up the new values
the strange thing is
<calaos:input file_type="json" gui_type="analog_in" id="input_63" name="prises" path="watt" period="10000" type="WebInputAnalog" url="http://10.0.0.2/currentcostdata_30.txt" visible="true"/>
is working
Compilation error:
views/ActivityWebView.cpp: In member function ‘void ActivityWebView::buttonCallback(void_, Evas_Object_, std::string, std::string)’:
views/ActivityWebView.cpp:220:69: error: ‘elm_web_url_get’ was not declared in this scope
elm_web_uri_get(web));
^
views/ActivityWebView.cpp:224:41: error: ‘elm_web_url_get’ was not declared in this scope
string url = elm_web_uri_get(web);
Informations of Chips into Calaos Server. (Motherboard Kontron 886LCD-M)
We need to use eina_prefix in calaos_base for calling calaos_mail, calaos_thumb,...
Some error messages, but calaos home works correctly:
for example:
ERR<2230>:elementary elm_button.c:341 elm_button_add() could not add 0x9f5d8f8 as sub object of 0x9f5d4d8
Here in after the error, for the newest version posted on 07.03 at 7:00pm :
'elm_web_url_set’ was not declared in this scope'
make[3]: Entering directory /home/maison/calaos_base/src/bin/calaos_home' CXX views/ActivityWebView.o views/ActivityWebView.cpp: In member function ‘void ActivityWebView::buttonCallback(void*, Evas_Object*, std::string, std::string)’: views/ActivityWebView.cpp:198:69: error: ‘elm_web_url_get’ was not declared in this scope views/ActivityWebView.cpp:202:41: error: ‘elm_web_url_get’ was not declared in this scope views/ActivityWebView.cpp: In member function ‘void ActivityWebView::goToCallback(std::string)’: views/ActivityWebView.cpp:228:37: error: ‘elm_web_url_set’ was not declared in this scope make[3]: *** [views/ActivityWebView.o] Error 1 make[3]: Leaving directory
/home/maison/calaos_base/src/bin/calaos_home'
make[2]: *** [install-recursive] Error 1
make[2]: Leaving directory /home/maison/calaos_base/src/bin' make[1]: *** [install-recursive] Error 1 make[1]: Leaving directory
/home/maison/calaos_base/src'
make: *** [install-recursive] Error 1
Remove the cgi binary, and merge it with the JSON api in calaos_server (this depends on the inclusion of the json api into calaos_server). Once it is done displaying graphs on calaos_web/webapp would be easy
Only calaos_server need r/w access to datalogger.eet with that solution
Serve the json api from calaos_server. For the HTTP server, use a proxy to route request to calaos_server. Add /api and /api.php alias for compatibility
Add universal remote control (Logitech Harmony range) to control calaos server scenario. Proposed solution: Install LIRC on a RPI (with IR dongle) and drive it to send some requests to calaos.
A nice feature to have could be to be able to lock a specific IO with a PIN code. It allows for example to lock a input or output and a specific keyboard would be displayed when trying to modify the variable. It could be used in alarms or to lock critical parts of the configuration (heating control that can only be changed by parents and not childrens...)
Implementation details:
In calaos home when you create a scenario with an action "clignotement" ou "extinction dans x secondes" is not working. From what it seems, the wrong action is selected in the list, and therefore the action is not the right one
Hello,
In calaos_home, the screensaver does not work.
(with the meleg-20140305 image)
As a lot of exotic commands (like for example favorites playlist play item_id:X ) are not available from calaos, we could circumvent this limitation by adding a CMD custom option like the one in the av receivers section
SEGV observed when trying to add multiple second note widget.
Steps to reproduce.
while(1)
{
Main Screen -> Add New Widget ->Notes
}
gdb trace is as follows.
INF<29379>:evas_main lib/evas/canvas/evas_events.c:1306 _canvas_event_feed_mouse_up() ButtonEvent:up time=2085669269 x=512 y=292 button=1 downs=1
ERR<29379>:eo lib/eo/eo_ptr_indirection.x:275 _eo_obj_pointer_get() obj_id (nil) is not pointing to a valid object. Maybe it has already been freed.
Program received signal SIGSEGV, Segmentation fault.
_elm_list_item_unfocused (it=0xbad040) at elm_list.c:1025
1025 if (!sd->focused_item ||
(gdb) bt
#0 _elm_list_item_unfocused (it=0xbad040) at elm_list.c:1025
#1 0x00007ffff7aa3fe1 in _item_focus_set_hook (it=0xc99970, focused=10 '\n') at elm_list.c:1700
#2 0x00007ffff7aa29f3 in _mouse_up_cb (data=0xc99970, evas=0xa, o=0x7ffff49269e0 <_IO_stdfile_2_lock>, o@entry=0x8000018120001a4b, event_info=0x7fffffffd6c0) at elm_list.c:1464
#3 0x00007ffff75f29f3 in _eo_evas_object_cb (data=0xbea9f0, eo_obj=0x8000018120001a4b, desc=, event_info=0x7fffffffd6c0) at lib/evas/canvas/evas_callbacks.c:130
#4 0x00007ffff3f26e98 in _ev_cb_call (obj_id=0x8000018120001a4b, class_data=0xd7c020, list=) at lib/eo/eo_base_class.c:690
#5 0x00007ffff3f219e3 in _eo_op_internal (p_list=0x7fffffffd448, op=16, op_type=EO_OP_TYPE_REGULAR, cur_klass=0x885f30, eo_ptr=0xd7bfe0, line=302, file=0x7ffff76ff518 "lib/evas/canvas/evas_callbacks.c") at lib/eo/eo.c:306
#6 _eo_dov_internal (p_list=0x7fffffffd448, op_type=EO_OP_TYPE_REGULAR, klass=0x885f30, obj=0xd7bfe0, line=302, file=0x7ffff76ff518 "lib/evas/canvas/evas_callbacks.c") at lib/eo/eo.c:338
#7 _eo_obj_dov_internal (p_list=0x7fffffffd448, obj=0xd7bfe0, line=302, file=0x7ffff76ff518 "lib/evas/canvas/evas_callbacks.c") at lib/eo/eo.c:359
#8 eo_do_internal (file=file@entry=0x7ffff76ff518 "lib/evas/canvas/evas_callbacks.c", line=line@entry=302, obj_id=obj_id@entry=0x8000018120001a4b) at lib/eo/eo.c:396
#9 0x00007ffff75f2fd7 in evas_object_event_callback_call (eo_obj=0x8000018120001a4b, obj=0xd7c050, type=EVAS_CALLBACK_MOUSE_UP, event_info=0x7fffffffd6c0, event_id=19501) at lib/evas/canvas/evas_callbacks.c:302
#10 0x00007ffff75f30a0 in evas_object_event_callback_call (eo_obj=, obj=0xd6e6c0, type=EVAS_CALLBACK_MOUSE_UP, event_info=0x7fffffffd6c0, event_id=19501) at lib/evas/canvas/evas_callbacks.c:322
#11 0x00007ffff75fd81d in _canvas_event_feed_mouse_up (eo_e=, _pd=, list=) at lib/evas/canvas/evas_events.c:1361
#12 0x00007ffff3f219e3 in _eo_op_internal (p_list=0x7fffffffd798, op=402, op_type=EO_OP_TYPE_REGULAR, cur_klass=0x866b50, eo_ptr=0x874310, line=1292, file=0x7ffff76ffc6a "lib/evas/canvas/evas_events.c") at lib/eo/eo.c:306
#13 _eo_dov_internal (p_list=0x7fffffffd798, op_type=EO_OP_TYPE_REGULAR, klass=0x866b50, obj=0x874310, line=1292, file=0x7ffff76ffc6a "lib/evas/canvas/evas_events.c") at lib/eo/eo.c:338
#14 _eo_obj_dov_internal (p_list=0x7fffffffd798, obj=0x874310, line=1292, file=0x7ffff76ffc6a "lib/evas/canvas/evas_events.c") at lib/eo/eo.c:359
#15 eo_do_internal (file=file@entry=0x7ffff76ffc6a "lib/evas/canvas/evas_events.c", line=line@entry=1292, obj_id=) at lib/eo/eo.c:396
#16 0x00007ffff75fc703 in evas_event_feed_mouse_up (eo_e=, b=, flags=flags@entry=EVAS_BUTTON_NONE, timestamp=, data=data@entry=0x0) at lib/evas/canvas/evas_events.c:1292
#17 0x00007ffff1f0a2d4 in _ecore_event_evas_mouse_button (e=0xd8ab00, press=ECORE_UP, faked=) at lib/ecore_input_evas/ecore_input_evas.c:375
#18 0x00007ffff65f1a57 in _ecore_call_handler_cb (event=, type=, data=, func=) at lib/ecore/ecore_private.h:359
#19 _ecore_event_call () at lib/ecore/ecore_events.c:562
#20 0x00007ffff65f8a35 in _ecore_main_loop_iterate_internal (once_only=once_only@entry=0) at lib/ecore/ecore_main.c:2039
#21 0x00007ffff65f8d47 in ecore_main_loop_begin () at lib/ecore/ecore_main.c:1042
#22 0x000000000040ff30 in main (argc=1, argv=0x7fffffffdd08) at main.cpp:92
When forcing the InputSwitchTriple to a value, the value is not reset after 250ms. It is the case when pressing the switch manually
In configure.ac add detection of gcc to be at least 4.8. It does not compile with a lower gcc version because of the use of C++11
Sometimes something connected to an output is out of order.
In the same time, this output can be controlled by many scenarios or rules.
It is then very painful to adjust every scenario/rule to remove the use this output. And back afterwards.
Therefore the need of a way to set an I/O to forced operation (on or off for a digital output).
Actual example : broken shutter.
listen command allows to use the connection and send command. The doc says the opposite.
Add support for XBMC audio part. We could use the Json RPC API for that :
http://wiki.xbmc.org/?title=JSON-RPC_API
text is truncated in genlists in efl >= 1.9
Add the ability to hide the scenario variables on main display -> only displayed in rooms.
When click-on add widget button, Calaos Home crashed:
calaos_home: symbol lookup error: /usr/lib/calaos/widgets/note/module.so: undefined symbol: _ZN5Utils10einaLoggerEPKc
Translation! At least in english/french
As a lot of strings are directly assigned in edje, we first need to separate text from edje to set it in C++ code.
Few images are also rasterized with text, it has to be extracted to be set inside the C++ code.
As many have reported that SmartShutter are not working anymore, I open a new issue to check that.
Get the flickr widget back on calaos_home desktop. (it was using flick_curl, and this is not a dependency of calaos_base anymore, a new solution should be found)
Add support for MPD for supported audio devices
We need to work on getting audio support to EMS with an API, and then add that to calaos...
AV receivers are not listed in the scenario section on the calaos home interface
When sending command "input set ..." calaos_server does not relay the changes to the event system (listen mode)
Finish calaos_home configuration pannel, it's actually an empty menu and need to be filled.
Configuration (local_config.xml, io.xml, rules.xml) doesn't contain version. It could be interesting to add such feature in each files, and keep a trace of each version to be able to come back to a working copy, if something wrong happen.
calaos_home network's code is not finished. It does not reconnect to the server if the server restarts. And the reload mechanism is not implemented. There is also some problems when calaos_home is started before calaos_server
when using impulse command on a dmx light, the light turns on but never blink nor turns off on any given pattern
DBG<8176>:calaos_rule Rule.cpp:67 bool Calaos::Rule::Execute()() Rule(Couloirs,Detecteur salon test): Trying execution...
DBG<8176>:calaos_rule.condition.standard Rules/ConditionStd.cpp:182 virtual bool Calaos::ConditionStd::Evaluate()() Ok
INF<8176>:calaos_rule Rule.cpp:75 bool Calaos::Rule::Execute()() Rule(Couloirs,Detecteur salon test): Starting execution (1 actions)
INF<8176>:calaos_output IO/OutputLightDimmer.cpp:65 virtual bool Calaos::OutputLightDimmer::set_value(std::string)() output_9: got action, impulse 2000 1000 3000
INF<8176>:calaos_output IO/OutputLightDimmer.cpp:321 void Calaos::OutputLightDimmer::impulse_extended(std::string)() output_9: got extended impulse action, parsing blinking pattern...
DBG<8176>:calaos_output IO/OutputLightDimmer.cpp:344 void Calaos::OutputLightDimmer::impulse_extended(std::string)() output_9: Add blink step True for 2000ms
DBG<8176>:calaos_output IO/OutputLightDimmer.cpp:344 void Calaos::OutputLightDimmer::impulse_extended(std::string)() output_9: Add blink step False for 1000ms
DBG<8176>:calaos_output IO/OutputLightDimmer.cpp:344 void Calaos::OutputLightDimmer::impulse_extended(std::string)() output_9: Add blink step True for 3000ms
INF<8176>:calaos_output IO/OutputLightDimmer.cpp:65 virtual bool Calaos::OutputLightDimmer::set_value(std::string)() output_9: got action, on
DBG<8176>:calaos_output Output.cpp:43 virtual void Calaos::Output::EmitSignalOutput()() output_9
DBG<8176>:calaos_rule ListeRule.cpp:119 virtual void Calaos::ListeRule::ExecuteRuleSignal(std::string)() Mutex locked, execute rule later for input output_9
DBG<8176>:calaos_ipc IPC.cpp:97 void IPC::SendEvent(std::string, std::string, void*)() (events , output output_9 state%3A100) : 3 events waiting.
DBG<8176>:calaos_output Output.cpp:43 virtual void Calaos::Output::EmitSignalOutput()() output_9
DBG<8176>:calaos_rule ListeRule.cpp:119 virtual void Calaos::ListeRule::ExecuteRuleSignal(std::string)() Mutex locked, execute rule later for input output_9
DBG<8176>:calaos_ipc IPC.cpp:97 void IPC::SendEvent(std::string, std::string, void*)() (events , output output_9 state%3A100) : 4 events waiting.
DBG<8176>:calaos_rule.action.standard Rules/ActionStd.cpp:143 virtual bool Calaos::ActionStd::Execute()() Ok
INF<8176>:calaos_rule Rule.cpp:81 bool Calaos::Rule::Execute()() Rule(Couloirs,Detecteur salon test): Execution done.
when using Dali or Dmx, you can't use the impulse function in the action choices as it's not implemented (choice available for standard outlets and lights outputs)
calaos_server under ubuntu 13.10
when using a decimal webanaloginput in a Lua script, the dot as separation mark transforms itself into a comma after a few hours, leading to some type errors
I can confirm that the command
LANG=C calaos_server
is a valid workaround
The source X command designed to change sources on the receivers doesn't work, nothing happends when sending it
INF<8176>:calaos_rule Rule.cpp:75 bool Calaos::Rule::Execute()() Rule(Couloirs,Detecteur salon test): Starting execution (2 actions)
INF<8176>:calaos_output Audio/AVReceiver.cpp:368 virtual bool Calaos::IOAVReceiver::set_value(std::string)() amp_0 got action, source 1
DBG<8176>:calaos_rule.action.standard Rules/ActionStd.cpp:143 virtual bool Calaos::ActionStd::Execute()() Ok
we can circumvent the problem using the custom command with the syntaxe
custom @MAIN:INP=AV1 or @MAIN:INP=HDMI1 etc...
After a new installation of OS (Ubuntu 14.04), Calaos Home still on "loading message".
Also sometimes Calaos server stops when I click for the first time on "My House" button of calaos_home.
Installation:
Based on tutorial : http://www.calaos.fr/wiki/compilation
Add libevas1-engines-x
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.