@jchenaud said in MMM-Fitbit:
e i have make something fail
hey for new user i have find the probleme
replace this.config.update_interval*60*1000);
by
this.config.update_interval*1000);
@jchenaud said in MMM-Fitbit:
e i have make something fail
hey for new user i have find the probleme
replace this.config.update_interval*60*1000);
by
this.config.update_interval*1000);
awesome !!!
just one think : update dont work : i have update_interval: 60 but my data never change (i have make a synchronization on my charg2 on my phone and my data are on net )
for update i need relaunch my MM
maybe i have make something fail
hi ! thk for modul.
i have just one problem : i need to make definition lower because my Pi go slowly with video how i am suppose to do ?
@Sean you are awesome !!!
my module almost work
just one problem i need to give a position in config. i think i have miss something
Module.register("MMM-keylogger",{
defaults: {
updateInterval: 1500,
},
notificationReceived: function(noti, payload, sender) {
Log.log(`notif : ${noti}`);
switch(noti) {
case 'MODULE_DOM_CREATED':
this.initMyDOM()
break
}
},
initMyDOM: function() {
var wrapper = document.createElement("div")
wrapper.id = "myDOM"
var container = document.body
container.appendChild(wrapper)
Log.log(`init DOM `);
var timer = setInterval(()=>{
var d = document.getElementById("myDOM")
d.innerHTML = this.dataFile
Log.log(`key : ${d.innerHTML} , ${this.dataFile} `);
if(d.innerHTML){
switch(d.innerHTML) {
case "Right":
this.sendNotification("PAGE_INCREMENT");
break;
case "Left" :
this.sendNotification("PAGE_DECREMENT");
break;
default:
Log.log(`key : ${d.innerHTML} pressed but not assigned`);
}
this.sendSocketNotification("Clear_key")
}
}, 1500)
},
start: function(){
console.log(this.name + " has started...!!!!!!");
this.sendSocketNotification("START", this.config);
},
socketNotificationReceived: function(notification, payload) {
if(notification === "KEY_P"){
this.dataFile = payload;
// this.updateDom();
}
},
if i don’t give position on config its don’t work ! if i have understand what you have say. this is suppose to work
other question : one of my other module have subitly stop to work and make same error but in this module in need position and update with Miror display. so my question is : this is possible this modification have impact on other module ?
@sean
thk for explain. i will try something different to get.getDom().
have you an idea for appendChild error ?
@Sean
thanks you have suppress the first error on screen-shot
but my modul write something on screen and i don’t want that but its can be cool for debug
@doublet
i am not sure to understand
if i remove my module i have one error (i correct after if i can)
but the looping are ok
my module
Module.register("MMM-keylogger",{
curentPage: -1,
defaults: {
updateInterval: 1000,
},
start: function(){
console.log(this.name + " has started...!!!!!!");
this.sendSocketNotification("START", this.config);
},
socketNotificationReceived: function(notification, payload) {
if(notification === "KEY_P"){
this.dataFile = payload;
this.updateDom();
}
},
getDom: function(){
var wrapper = document.createElement("div");
wrapper.innerHTML = this.dataFile
if(this.dataFile){
switch(wrapper.innerHTML) {
case "Right":
this.sendNotification("PAGE_INCREMENT");
break;
case "Left" :
this.sendNotification("PAGE_DECREMENT");
break;
default:
Log.log(`key : ${wrapper.innerHTML} pressed but not assigned`);
}
this.sendSocketNotification("Clear_key")
}
return wrapper;
},
});
const NodeHelper = require("node_helper");
const fs= require("fs");
module.exports = NodeHelper.create({
//here comes the part of the nodehelper after the 3 dots as posted above
socketNotificationReceived: function(notification, payload) {
if(notification === "START"){
this.config = payload;
this.readData();
setInterval(() => {
this.readData();
}, this.config.updateInterval);
}
if(notification === "Clear_key")
{
fs.open('Key_pres.txt', 'r+', function(err, fd) {
if (err) {
return console.error(err);
}
fs.ftruncate(fd, function(err){
if (err){
console.log(err);
}
console.log("supose to trucate");
})
});
}
},
readData: function(){
fs.readFile("Key_pres.txt", "utf8", (err, data) => {
if (err) throw err;
this.sendSocketNotification("KEY_P", data);
})
}
});
i have no warning of no declare class or something like that on VS
sorry but i beginner with organisation of MM
thanks for your rapidity :)
first of all hello :)
i make my module and i have 2 looping error but she is not located on my code

do you have idea?
thk for your attention
hey i remake all process but nothing new . i am alone in this case ?
just my log when all looks ok
MagicMirror git:(master) ✗ npm start
> magicmirror@2.4.1 start /home/pi/MagicMirror
> sh run-start.sh
Starting MagicMirror: v2.4.1
Loading config ...
Loading module helpers ...
No helper found for module: alert.
Initializing new module helper ...
Module helper loaded: updatenotification
No helper found for module: clock.
No helper found for module: compliments.
Initializing new module helper ...
Module helper loaded: newsfeed
No helper found for module: MMM-EyeCandy.
Initializing new module helper ...
Module helper loaded: Print_text_from_txt
Initializing new module helper ...
Module helper loaded: MMM-kalliope
Initializing new module helper ...
Module helper loaded: MMM-KeyBindings
No helper found for module: MMM-pages.
All module helpers loaded.
Starting server on port 8080 ...
Server started ...
Connecting socket for: updatenotification
Connecting socket for: newsfeed
Starting module: newsfeed
Connecting socket for: Print_text_from_txt
Starting module helper: Print_text_from_txt
Connecting socket for: MMM-kalliope
MMM-kalliope is started
Connecting socket for: MMM-KeyBindings
MMM-KeyBindings helper has started...
Sockets connected & modules started ...
Launching application.
Create new news fetcher for url: https://www.tdg.ch/rss_ticker.html - Interval: 300000
MMM-kalliope received a socket notification: CONNECT - Payload: null
hey thk for module !
i try to use it but i have some problem:
i have put that on my conf file .
{
module : 'MMM-KeyBindings' ,
config : {
enableNotifyServer : false
}
},
i just want to use a local keyboard for now and i probably change after for remote.
and on my module of pages organisation
i have put your config :
Module.register("Print_text_from_txt",{
curentPage: -1,
defaults: {
updateInterval: 1000,// 30 * 60 * 1000 //reads the file every 30 mins
/*** defaults ***
*
* Add items below to your moduleName.js's `defaults` object
*
*/
/*** MMM-KeyBindings STANDARD MAPPING ***/
/* Add the "mode" you would like to respond to */
keyBindingsMode: "DEFAULT",
keyBindings: {
/* Add each key you want to respond to in the form:
* yourKeyName: "KeyName_from_MMM-KeyBindings"
*/
Right: "ArrowRight",
Left: "ArrowLeft",
/* ... */
},
},
/////////////////////////////
start: function(){
this.setupKeyBindings(); //key binding test
this.sendSocketNotification("START", this.config);
},
/////////////////////////////
notificationReceived: function(notification, payload){
if (this.validateKeyPress(notification, payload)) { return; }
if (notification === "PAGE_NUMBER_IS")
{
this.curentPage = payload
this.sendNotification("PAGE_CHANGED", this.curentPage);
}
///////////////////////////
i have clone directory on my module folder.
i have one error on console but she not cause by the module
TypeError: Failed to execute 'appendChild' on 'Node': parameter 1 is not of type 'Node'.
at updateModuleContent (main.js:206)
at main.js:139
at new Promise (<anonymous>)
at updateDomWithContent (main.js:137)
at main.js:119
at <anonymous>
i have probably miss something but i dont find :(
i haven’t notification on console
sorry for my bad language
and thanks for your help
edit:
i have miss on Line on config file
but notification is not hear and probably never send :(
@edward-shen thk :) i will try on the next week .
hey
i want to make something with one oximeter.
i can plug him with gpio. i want to display real time graph like an ECG. if its not possible i can make that with python but i need tips for display window ECG on MM
sorry for my english i hope you can understand.
have a nice day !!
i know its not true “ECG” :)
@edward-shen
merci !! je n’est pas utilisée votre code car je ne vois pas trop comment il diffère de :
if (this.curPage != payload )
{
switch (notification) {
avec ce if sa semble éviter les rechargement de la page. mais cette solution me conviens pas vraiment en effet : elle ne permet pas de stopper les notification. il faudrait que je puise accéder a curPage depuis un autre module pour éviter d’émettre d’est notification inutile.
@edward-shen said in MMM-pages & MMM-pages-indicator - Lightweight module pages on your mirror!:
mande d’extraction pour ajouter des fonctionnalités?
hey sorry for this wake up :)
i need to acces for id to curent page. i think its possible but i dont find :(.
because i need change page if one action have been made juste if im not already on this page
i am realy beginner whith js.
sorry for this bad English
what im suppose to do for juste Display hello when I say hello on MM since beginning
I am completely lost sorry
have a nice day
my MM are on http://localhost:8080/
i dont now for Kalliope
i try to find with --debug but nothing
i try to make my .yml but i have somme error.
Traceback (most recent call last):
File "/usr/local/bin/kalliope", line 11, in <module>
load_entry_point('kalliope==0.5.1', 'console_scripts', 'kalliope')()
File "/usr/local/lib/python2.7/dist-packages/kalliope-0.5.1-py2.7.egg/kalliope/__init__.py", line 136, in main
brain_loader = BrainLoader(file_path=brain_file)
File "/usr/local/lib/python2.7/dist-packages/kalliope-0.5.1-py2.7.egg/kalliope/core/Models/Singleton.py", line 6, in __call__
cls._instances[cls] = super(Singleton, cls).__call__(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/kalliope-0.5.1-py2.7.egg/kalliope/core/ConfigurationManager/BrainLoader.py", line 33, in __init__
sl = SettingLoader()
File "/usr/local/lib/python2.7/dist-packages/kalliope-0.5.1-py2.7.egg/kalliope/core/Models/Singleton.py", line 6, in __call__
cls._instances[cls] = super(Singleton, cls).__call__(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/kalliope-0.5.1-py2.7.egg/kalliope/core/ConfigurationManager/SettingLoader.py", line 66, in __init__
self.settings = self._get_settings()
File "/usr/local/lib/python2.7/dist-packages/kalliope-0.5.1-py2.7.egg/kalliope/core/ConfigurationManager/SettingLoader.py", line 102, in _get_settings
default_stt_name = self._get_default_speech_to_text(settings)
File "/usr/local/lib/python2.7/dist-packages/kalliope-0.5.1-py2.7.egg/kalliope/core/ConfigurationManager/SettingLoader.py", line 161, in _get_default_speech_to_text
raise SettingNotFound("%s setting not found" % e)
kalliope.core.ConfigurationManager.SettingLoader.SettingNotFound: 'default_speech_to_text' setting not found
thk but i have the same problème i have check my console and i have 3 Error ! 
sorry, but I am beginning with MM and Kaliope i think i have missed somthing
Hello , I want to use Kalliope on my MM but I Have installed Kalliope (and its work i can say “hello” ) i Have MMM-kalliope on my modules.
i have made config.js but nothing display on my MM :(
what i suppose to do ?
my Englishis is not good so don’t blame me please
have a nice day !