@mirror.master ah, so you got it to display two different instances of the module? Just Carousel doesn’t let you input those two instances because it requires a name?! Then I recommend using MMM-ProfileSwitcher + MMM-Remote-Control and/or MMM-ModuleScheduler. Instead of having to provide a list of modules which form one “page”, you can assign every module a list of “pages” it should be displayed on. This eliminates the problem of modules being named the same / being duplicates.
Just install ProfileSwitcher and RemoteControl, assign some “classes” (think of it as pages) to modules (e.g. “transport1” and “transport2” to the transport instances) and switch between them using URLs like here. I guess ModuleScheduler isn’t necessary since ProfileSwitcher already comes with timing functionalities. Just mentioned for completeness.
Read the statement by Michael Teeuw here.
Posts
-
RE: How can i toggle various destinations via transport module?
-
RE: How can i toggle various destinations via transport module?
@mirror.master ah i see. I don’t think modules are meant to be used in form of multiple instances of the same module. For example, see the way
node_helperis used (even when changing some names/parameters in config). Some modules may work with multiple instances of themselves, some don’t.The module you are talking about is MMM-LocalTransport, correct? It’s not really clear by the term “localtransport module”. If I see correctly, you should be able to use multiple instances of this module just by adding it two times in the config file. If not, see below.
As far as I understand, you already tried to copy the whole module under different name? In other words, you created a “new” module which does exactly same / has the same code as the one you want to use, but has a different name (folder named “newModule” -> file named “newModule.js” -> within the line
Module.register('newModule'))?! This is definitely possible and should work unless the module itself uses some sort of API which restricts multiple accesses.Alternative way IF the module itself provides the option to set destinations via notifications (Note: MMM-LocalTransport doesn’t seem to offer that): use MMM-RemoteControl and/or MMM-ModuleScheduler to swap destinations by remote command and/or timing.
IF it doesn’t, implement it yourself (and use together with the modules mentioned above). In most cases, it is not difficult: basically the following structure should applynotificationReceived: function(notification, payload) { if (notification==="SET_FROM_TO") { /* 1. set variable containing destination to new destination defined by payload; * may be this.config.origin/this.config.destination or something * 2. make changes visible; probably by doing this.update() or this.updateDom(); * So, for example for MMM_LocalTransport something like this should work: */ this.config.origin = payload.origin; this.config.destination = payload.destination; this.update(); } } -
RE: Black blank screen
@dhirajv12 Never seen this. Googled it. Found this.
If it works now, I wouldn’t worry too much. -
RE: How can i toggle various destinations via transport module?
@mirror.master You’re welcome! The information provided are rather general. Feel free to ask again, if you need more specific help.
-
RE: Black blank screen
@dhirajv12 Seems more like you are missing some dependency. Try reinstalling from scratch…
-
RE: How can i toggle various destinations via transport module?
@mirror.master Have a look here. I don’t know how you want to trigger the swapping, but in general the possibilities described in the thread are the ways to go.
-
RE: Change heading color
@Mykle1 Why bother with individual modules? If you do it for every module, isn’t it the same as simply styling
headerin general?I don’t know if we agree on the term “header”. For me, the following changes the color of the text of every module-headline to green:
#custom.css header { color: green; }(Note:
.headerdoes not!) -
RE: German "Umlaute" (ä, ü, ö, ß) in compliments module
@beck0r I guess you changed something ;) just restarting doesn’t brake anything.
- So, what do you see? Standard compliments? Nothing? Error message?
- Does it work with compliments embedded into config file?
- Could you post config and remote compliments file?
-
RE: German "Umlaute" (ä, ü, ö, ß) in compliments module
@beck0r I’ve got at least one “ö” in my compliments and it works; not sure why, though. You can try using an external .json file for your compliments, since thats what I did.
-
RE: External Compliments list limitations and randomness
@RE_Magic_Mirror Well…it depends.
- If switching to develop branch fixed your problem, then you want to stay at develop until the changes are merged into the master branch. Until then, you can either update (see https://github.com/MichMich/MagicMirror#updating-your-magicmirror) or decide to ignore updates. If you don’t want to see the notification, you have to disable the update notification module.
- If it did not help with your problem, then you are usually better off using the master branch, so I would suggest to switch back to master.
-
RE: MMM-Podcast (or playing a video on command at all) without button?
@SurfingCA IIRC MMM-Podcast works together with MMM-Button which enables you to use a hardware button to start playing the video/podcast. So you can either (1) use this OR (2) emulate its behaviour using MMM-RemoteControl.
(1) is properly documented I guess.
For (2) you have to send the exact notification MMM-Button would have sent. By looking through source code, you’ll see that it isBUTTON_PRESSED(with a payload oftrue, which gets ignored in MMM-Podcast anyway). So, you should be able to usehttp://ip:8080/remote?action=NOTIFICATION& notification=BUTTON_PRESSEDto activate MMM-Podcast to play the video. Note: obviously you have to replaceipwith the correct IP and you have to remove the whitespace between&andnotificationwhich I had to insert to prevent&andnotto get converted to¬on this board. -
RE: MMM-Traffic Multiple Routes
@BlackTalon I’ve seen this recently on this board. Is this what you are looking for?
-
RE: External Compliments list limitations and randomness
@RE_Magic_Mirror maybe there was a comma missing somewhere in the large amount of lines (sometimes not easy to spot). Good to hear you got it to work properly.
One more note: you should never need to do changes to compliments.js (or any other source code file). Like for (nearly) every module, it should be sufficient to change the config file (and sometimes extra remote files like for example the compliments file). In particular, the location of the external compliments file should be defined in the config file.
-
RE: External Compliments list limitations and randomness
@RE_Magic_Mirror “this guy” probably made some changes to the compliments.js file. If you didn’t do any changes to the source code itself, then changing branches (like updating MM) should be a piece of cake. You don’t lose anything by trying. Either it doesn’t work and doesn’t change anything (“aborting”) or you can change back at anytime (
git checkout master,git pull).Btw, what do you mean by “seems to break it” when talking about the larger list?
-
RE: External Compliments list limitations and randomness
@RE_Magic_Mirror If you don’t use ‘anytime’ or any of the weather-based options, then this problem indeed doesn’t apply to you. However, it’s not much effort to make, so I suggest you test using the develop branch anyway.
The statement you quoted just means, that you can switch to the develop branch by navigating into the MagicMirror main directory and then using the command
git checkout develop(andgit pull).Have you applied statistical hypothesis tests? Human brains (=intuition) are bad at estimating probabilities, it might be just correct as it is?! I’ve used a file with around 15 compliments and for me it seems to work fine. I can’t think of a reason, why the probability distribution should change with numbers of entries…
-
RE: External Compliments list limitations and randomness
@RE_Magic_Mirror AFAIK, there is a bug in the handling of some categories of compliments. As a result, the list of possible compliments regulary gets extended by copies of the same compliment. For reference, see here.
So, the random number generator works fine, it just picks a random compliment from a list with multiple copies of some compliments and therefore the probability is not uniformly distributed anymore.
However, -as mentioned in the thread above- this problem is fixed in the develop branch. So, if you want it to work correctly, you can switch to the develop branch. -
RE: Remote control using your iphone
@Hanauta Or you can just use the great MMM-Remote-Control module.
-
RE: Move / load div modules around
@romain Why not set some random position and hide all (other) modules on startup with the method you use at runtime? As far as I know it is possible to get a list of all modules.
MMM-ProfileSwitcher does something similar at startup (shows only modules with class “default” at start). Maybe you can look into their code to see how they do it?! Or you just use the MMM-ProfileSwitcher itself just to hide all modules at startup (quick and dirty).
-
RE: Multiple Pages of Modules using CSS
@strawberry-3.141 another possibility to do something similar is MMM-ProfileSwitcher + MMM-Remote-Control. I’ve used this to imitate “pages” and it worked quite well.
Both alternatives don’t naturally come with those fancy arrows and dots, though.
-
RE: How do you get the taskbar to show over the Magic Mirror?
@PhilsterM9 So you mean you’d the mirror not to be fullscreen?!