Git Product home page Git Product logo

mmm-pages's Introduction

Maintainer needed

Hello, it's been 5 years since I've written this! While I'm happy to see it thriving, it's also about time I step away. I haven't had a magic mirror up in years, and to be frank, I'm hoping someone else will be willing to take up maintainership of the project.

I find this project to be in a near complete form. Other than a few mishaps of me not having proper testing before pushing out code, more often than not any problems that people have usually isn't often because of this project. The few issues that do exist aren't very hard to fix nor are they severe that they impact the project in any large manner. It's just I haven't had the time nor motivation to fix them.

I don't think there are expectations for this project to have new features, so a maintainer should really only need to just make sure people are getting help when they raise issues and fix the rare bug that pops out every so often. If you're interested, please don't hesitate to reach out.


MMM-pages

This MagicMirror² Module allows you to have pages in your magic mirror! Want to have more modules in your magic mirror, but want to keep the format? Or, want to have grouped modules that are themed together? Look no further!

Example

Note that this module does not provide any method of manually changing the page! You should ask other developers to add a notification to their modules, or add one yourself!

Installation

In your terminal, go to your MagicMirror's Module folder:

cd ~/MagicMirror/modules

Clone this repository:

git clone https://github.com/edward-shen/MMM-pages.git

Configure the module in your config.js file.

<self-promotion>

To display what page you're on, I'd highly recommend checking out my page indicator module.

<\self-promotion>

Using the module

To use this module, add it to the modules array in the config/config.js file. Note: module names used in the following example are fictitious.

modules: [
    {
        module: 'MMM-pages',
        config: {
                modules:
                    [[ "newsfeed" ],
                     [ "calendar", "compliments" ]],
                fixed: [ "clock", "weather", "MMM-page-indicator" ],
                hiddenPages: {
                    "screenSaver": [ "clock", "MMM-SomeBackgroundImageModule" ],
                    "admin": [ "MMM-ShowMeSystemStatsModule", "MMM-AnOnScreenMenuModule" ],
                },
        }
    }
]

Configuration options

Option Type Default Value Description
modules [[String...]...] [] A 2D String array of what each module should be on which page. Note that all entries must take their class name (e.g. this module's class name is MMM-pages, while the default modules may just have newsfeed, without the MMM- prefix.
fixed [String...] ["MMM-page-indicator"] Which modules should show up all the time.
excludes NA NA Deprecated. Use fixed instead.
hiddenPages {String: [String...]...} {} An Object defining special hiddenPages which are not available on the normal page rotation and only accassible via a notification. Modules defined in fixed are ignored and need to be also added if you wish to have them on any hidden page.
animationTime int 1000 Fading animation time. Set to 0 for instant change. Value is in milliseconds (1 second = 1000 milliseconds).
rotationTime int 0 Time, in milliseconds, between automatic page changes.
rotationDelay int 10000 Time, in milliseconds, of how long should a manual page change linger before returning to automatic page changing. In other words, how long should the timer wait for after you manually change a page. This does include the animation time, so you may wish to increase it by a few seconds or so to account for the animation time.
rotationHomePage int 0 Time, in milliseconds, before automatically returning to the home page. If a home page is not set, this returns to the leftmost page instead.
rotationFirstPage NA NA Deprecated. Use rotationHomePage instead.
homePage int 0 Which page index is the home page. If none is set, this returns to the leftmost page instead.
useLockString bool true Whether or not to use a lock string to show or hide pages. If disabled, other modules may override when modules may be shown. Advanced users only. Only override this if you know what you're doing.

For the module configuration option, the first element of the outer array should consist of elements that should be on the first page. The second element should consist of elements that should be on the second page, and so forth.

Notifications

The following is the list of notifications that MMM-pages will handle:

Notification Payload type Description
PAGE_CHANGED int MMM-pages will switch to the provided page index.
PAGE_INCREMENT int, Optional MMM-pages will increment the page, or by n times if a number is provided. Not providing a number is equivalent to sending a payload of 1. If there are no more pages to increment by, this will loop around to the first page.
PAGE_DECREMENT int, Optional MMM-pages will decrement the page, or by n times if a number is provided. Not providing a number is equivalent to sending a payload of 1. If there are no more pages to decrement by, this will loop around to the last page.
QUERY_PAGE_NUMBER None MMM-pages will respond with PAGE_NUMBER_IS with the current page index.
PAUSE_ROTATION None If MMM-pages is set to rotate, this will pause rotation until a RESUME_ROTATION notification is sent. This does nothing if rotation was already paused.
RESUME_ROTATION None If MMM-pages was requested to pause rotation, this will resume automatic rotation. This does nothing MMM-pages was not requested to pause.
HOME_PAGE None Return to the home page. If no home page is provided, return to the first page instead.
SHOW_HIDDEN_PAGE String MMM-pages will switch to the provided hidden page name.
LEAVE_HIDDEN_PAGE None MMM-pages will leave the currently showing hidden page and return to the previous showing page index.

The following is the list of notifications that MMM-pages sends out:

Notification Payload type Description
MAX_PAGES_CHANGED int This is sent only once during initialization of MMM-pages. This contains the number of pages defined in config.js.
NEW_PAGE int This notification is sent out on every page change and contains the current page index. This is to help other modules keep track of what the current page is. This is also sent out during initialization.
PAGE_NUMBER_IS int Sent in response to a QUERY_PAGE_NUMBER notification. Returns the current page index. This notification sends the same payload as NEW_PAGE.

Notes

This module responds to the notification PAGE_CHANGED and the payload strictly must be an integer. Note that this has strict error checking, so "3" will not work, while 3 will.

This module keeps track of pages by their index rather than their page number, so the leftmost page has an index of 0, the page to the right of that has an index of 1, and the page to the right of that has an index of 2. Thus, to change to the third page, your module should send out:

this.sendNotification("PAGE_CHANGED", 2);

This module keeps internal track of how many pages you have, defined by your config in the config file. There is no way to dynamically change the pages you have. If there arises a need, please create an issue.

This module does not enforce how other modules represents or even responds to MMM-pages notifications.

Initialization

This section provides documentation on what notifications the module sends on startup. This section isn't necessary to read for most users.

MMM-pages doesn't activate until we receive the DOM_OBJECTS_CREATED notification, as that notification ensures all modules have been loaded. On this notification, we send two notifications out, MAX_PAGES_CHANGED and NEW_PAGE, so other modules that would like to keep synchronized of the starting page and max pages have a way to determine which page to start on.

Hidden pages

The idea behind hidden pages is to be able to create special "modes" which are totally configurable by the user and are seperated from the "normal" MM² operation. Some examples would be a "guest", "admin" or "screensaver" mode, where only very specific modules are shown and you do not want to have them in your normal page roation.

These hidden pages are only accessible via notifications, so you need to send them from other modules. Examples integrations could be with touch, bots or voice commands. See also FAQ below.

FAQ

  • How do I interact with different pages?

    MMM-pages intentionally does not provide methods to interact with the pages. This is intentional by design, as there are too many ways to interact with a Magic Mirror. MMM-page-indicator does provide a way to click on the circles to change pages, but this requires the ability to click or tap on the circles itself. If no other method is available, MMM-pages provides an automatic rotation feature.

  • Help! My module is (above/below) another module in the same region but I want it to be somewhere else!

    The order of your config.js determines your module location. If you have two modules, both with position:bottom_bar, the one that is first listed will appear on top. The rest will appear in the same order you defined them in. If you want this module to be at the very bottom, define this module as the last module in your config.js file. If you want it to be on top in that region, make sure no other module is defined before it that has the same region.

  • Can I make a pull request?

    Please do! Feel free; I love improvements!

  • I want more config options!

    Please make an issue. Thanks!

mmm-pages's People

Contributors

burnallover avatar cowboysdude avatar dependabot[bot] avatar edward-shen avatar fifteen15studios avatar skuethe avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

mmm-pages's Issues

MMM-Pages only works in an intranet browser not on the mirror itself

Hi Edward,

first of all I want to thank you for your great work. The MMM-pages ist exactly what I am looking for.
I installed it and the MMM-page-indicator as well.

However, the mirror itself always shows every modul installed. No matter what page I open. It does not hide or show anything. I always see a 100 percent.
If I open the magic mirror in a intranet browser, the MMM-pages is working fine. I only see, what I configured in the config.js.

The MMM-page-indicator ist working fine. Even on the mirror itself it changes the radio buttons.

Do you have any idea what the problem might be?
Is it me or may the module might have a bug?

Thank you very much.

Greetings from Germany
McNose

Does this do some kind of overlay in background?

first of all thanks for your time and effort on this module :)

I have installed this and got this working as intended for now.

And just wondering does it override the "fullscreen_above" position?

Only reason I ask, and its seasonal, is I have MMM-Snow for the kids installed, and the snowflakes seem to fall behind this, instead of in front like they used to before i installed this.

So I guess, any way to make your layer transparent or...?

No biggy

I have no errors reported, and am on the latest MM

Change pages with voice

Hi Edward,
I've add your MMM-pages and MMM-page-indicator, and, thank you !
Because I saw a video on YouTube (https://www.youtube.com/watch?v=JogbkzNnVXI), I try to use Amazon Echo (MMM-AlexaControl) to change my pages but I think I need to use your notifications system and I don't understand this part... Do I need to use your "regarding notification" section to do what I want ? Can you help me please ?
Sorry for my English...
Thanks

Here is my code :

var config = {
address: "0.0.0.0", // Address to listen on, can be:
// - "localhost", "127.0.0.1", "::1" to listen on loopback interface
// - another specific IPv4/6 to listen on a specific interface
// - "0.0.0.0", "::" to listen on any interface
// Default, when address config is left out or empty, is "localhost"
port: 8080,
ipWhitelist: [], // Set [] to allow all IP addresses
// or add a specific IPv4 of 192.168.1.5 :
// ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.1.5"],
// or IPv4 range of 192.168.3.0 --> 192.168.3.15 use CIDR format :
// ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.3.0/28"],

useHttps: false, 		// Support HTTPS or not, default "false" will use HTTP
httpsPrivateKey: "", 	// HTTPS private key path, only require when useHttps is true
httpsCertificate: "", 	// HTTPS Certificate path, only require when useHttps is true

language: "fr",
timeFormat: 24,
units: "metric",
// serverOnly:  true/false/"local" ,
		     // local for armv6l processors, default
		     //   starts serveronly and then starts chrome browser
		     // false, default for all  NON-armv6l devices
		     // true, force serveronly mode, because you want to.. no UI on this device

modules: [
	{
		module: "alert",
	},
	{
		module: "updatenotification",
		position: "top_bar"
	},
	{
		module: "clock",
		position: "top_right"
	},
	{
		module: "calendar",
		header: "US Holidays",
		position: "top_left",
		config: {
			calendars: [
				{
					symbol: "calendar-check",
					url: "webcal://www.calendarlabs.com/ical-calendar/ics/76/US_Holidays.ics"					}
			]
		}
	},
	{
		module: "compliments",
		position: "lower_third",
		config:{
			updateIntervale: 10000,
			compliments:{
				morning: [
					  "Bonjour !",
					  "Passez une bonne journée !",
					  "Bonne journée !"
				],
				afternoon: [
					  "Bon après-midi"
				],	  
				evening: [
					  "Bonne soirée",
					  "Faites de beaux rêves",
					  "Bonne nuit :)"
				]
			}
		}
	},
	{
		module: "currentweather",
		position: "top_right",
		config: {
			location: "Rueil-malmaison, France",
			locationID: "6451979", //ID from http://bulk.openweathermap.org/sample/; unzip the gz file and find your city
			appid: "XXXXXXXXXXXXXXXXXXX"
		}
	},
	{
		module: "weatherforecast",
		position: "top_right",
		header: "Météo",
		config: {
			location: "Rueil-malmaison, France",
			locationID: "6451979", //ID from https://openweathermap.org/city
			appid: "XXXXXXXXXXXXXXXXXXXX"
		}
	},
	{
		module: "newsfeed",
		position: "bottom_bar",
		config: {
			feeds: [
				{
					title: "KORBEN",
					url: "http://korben.info/feed"
				}
			],
			showSourceTitle: false,
			showPublishDate: false,
			broadcastNewsFeeds: true,
			broadcastNewsUpdates: true
		}
	},
	{
		module: "newsfeed",
		position: "bottom_bar",
		config: {
			feeds: [
				{
					title: "BFM",
					url: "https://www.bfmtv.com/rss/info/flux-rss/flux-toutes-les-actualites/"
				}
			],
			showSourceTitle: false,
			showPublishDate: false,

		}
	},
	{
		module: "newsfeed",
		position: "bottom_bar",
		config: {
			feeds: [
				{
					title: "ANDROIDPIT",
					url: "https://www.androidpit.fr/feed/main.xml"
				}
			],
			showSourceTitle: false,
			showPublishDate: false,
			broadcastNewsFeeds: true,
			broadcastNewsUpdates: true
		}
	},
	{
		module: "newsfeed",
		position: "bottom_bar",
		config: {
			feeds: [
				{
					title: "01NET",
					url: "https://www.01net.com/rss/info/flux-rss/flux-toutes-les-actualites/"
				}
			],
			showSourceTitle: false,
			showPublishDate: false,
			broadcastNewsFeeds: true,
			broadcastNewsUpdates: true
		}
	},
	{
		module: "MMM-NowPlayingOnSpotify",
		position: "top_left",
		config: {
				clientID: "xxxxxxxxxxxxxxxxx",
				clientSecret: "xxxxxxxxxxxxxxxxx",
				accessToken: "xxxxxxxxxxxxxxxxx",
				refreshToken: "xxxxxxxxxxxxxxxxx"
		}
	},
	{
    		module: 'MMM-Remote-Control'
    		// uncomment the following line to show the URL of the remote control on the mirror
    		, position: 'bottom_left'
    		// you can hide this module afterwards from the remote control itself
    
		},	
		{
    		module: 'MMM-pages',
    		config: {
            		modules:
                			[["MMM-AlexaControl"],
                 			[ "MMM-NowPlayingOnSpotify", "MMM-Remote-Control"],
				[ "MMM-Globe"]],
            		fixed: ["clock", "weatherforecast", "newsfeed", "calendar","currentweather", "compliments", "MMM-page-indicator"],
    		}
		},
	{
    		module: 'MMM-page-indicator',
    		position: 'bottom_bar',
    		config: {
        				pages: 3,
    		}
		},
	{
		module: 'MMM-Globe',
		position: 'center',
		config: {
			style: 'europeDiscSnow',
			imageSize: 600,
			ownImagePath:'',
			updateInterval: 10*60*1000
		}
	},
	{
    		module: 'MMM-AlexaControl',
    		position: 'middle_center',
    		config:{
        			image: true,
			height: 50,
			width: 50,
        			pm2ProcessName: "mm",
        			vcgencmd: "vcgencmd",
			deviceName: "Mirroir"
    		}
		},
]

};

/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {module.exports = config;}

Cant change pages with alexa

Hello,
I have recently added the MMM pages to my mirror. I have only added one page.I would like to control it with my alexa as i dont have a touch screen.I set up it up on my Alexa and I can say Alexa turn on page 2 and it says it has turned on but the mirror dosnet do anything can someone help me please

How to rotate

Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

Describe the solution you'd like
A clear and concise description of what you want to happen.

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

Confusion

Where should I add:
this.sendNotification("PAGE_CHANGED", 2);
because I for some reason cannot see where to add this.

NOOB help. MMM-Pages appears to work but I wont rotate.... it does work exactly as programmed when clicking MMM-PageIndicator buttons with mouse.

Hi Guys thats for the support, and thanks for developing this modules Ed. I very much appreciate it. Can yourself (or any other more experienced user ) help me out with this simple problem I have.

When starting mirror npm start, All modules load properly. My homepage however is OVER-stacked with modules so I installed both modules (Pages and PageIndicator). I have added rotationtime but the pages wont change. However; when I mouse clock the pagebuttons on the page-indicator module, it works EXACTLY how I planned / designed the modules.

  • My MMM-Pages wont rotate pages. Its probably something simple. Herewith the most important parts or config.js:

{
module: 'MMM-Todoist',
position: 'bottom_right', // This can be any of the regions. Best results in left or right regions.
header: 'Shopping', // This is optional
config: { // See 'Configuration options' for more information.
hideWhenEmpty: true,
accessToken: 'XXXXXXXXXXXX',
maximumEntries: 10,
showProject: false,
updateInterval: 1601000, // Update every 10 minutes
fade: false,
// projects and/or labels is mandatory:
projects: ['XXXXXXXX'],
labels: [ "MagicMirror", "Important" ] // Tasks for any projects with these labels will be shown.
}
},

{
module: 'nstreinen',
position: 'top_left',
header: 'Rotterdam CS naar Laan vNOI',
config: {
apiKey:'XXXXXXXXXXX',
fromStation: 'RTD',
toStation: 'LAA',
maxEntries: 2
}
},

// letop jaarlijks de config file handmatig updaten met behulp van de afvalkalander van de gemeente.

{
module: 'MMM-MyGarbage',
position: 'top_right',
header: 'Container',
config: {
alert: 4,
weeksToDisplay: 1,
limitTo: 2,
fade: false,
dateFormat: "dddd D MMMM",
fadePoint: 0.25
}
},

{
module: "MMM-MotionDetector",
// position: "top_left", // Optional. This can be any of the regions. Displays debug informations.
config: {
captureIntervalTime: 1000,
scoreThreshold: 150,
timeout: 120000
// The config property is optional.
// See 'Configuration options' for more information.
}
},

// {
// module: "compliments",
// position: "lower_third"
// },

// niet zo boeiend dit is de standaard weather display app. per nu uitgeschakeld en geupgrade
//
// {
// module: "currentweather",
// position: "top_left",
// config: {
// location: "XXXXXXX",
// locationID: "XXXXXX", //ID from http://bulk.openweathermap.org/sample/city.list.json.gz; unzip the gz file and find your city
// appid: "XXXXXXXXXXXX"
// onlyTemp: "true",
// }
// },

// {
// module: "weatherforecast",
// position: "top_right",
// header: "Weather Forecast",
// config: {
// location: "New York",
// locationID: "5128581", //ID from http://bulk.openweathermap.org/sample/city.list.json.gz; unzip the gz file and find your city
// appid: "YOUR_OPENWEATHER_API_KEY"
// }
// },
{
module: "newsfeed",
position: "top_bar",
config: {
hideLoading: true,
ignoreOldItems: true,
ignoreOlderThan: 6000000,
// // The config property is optional.
// // If no config is set, an example calendar is shown.
// // See 'Configuration options' for more information.

		feeds: [
			{
				title: "NL Alert / Rijnmond veiligheidsregio",
				url: "https://rss.rijnmondveilig.nl/rotterdamrijnmond/index.rss",
			},
			{
				title: "NL Alert / Rijnmond veiligheidsregio",
				url: "https://crisis.nl/algemene-informatie-van-crisisnl/",
			},

		]
	},
},

{
module: "MMM-NLDepartureTimes",
position: "top_left",
header: "Randstadrail",
config: {
maxVehics: 4,
updateSpeed: 8,
locale: 'nl-NL',
tpc: {
'':{
'': [31008713, 31008712],
},
}
}
},

	{
	module: "newsfeed",
	position: "top_bar",	 
	config: {
	hideLoading: true, 
	updateInterval: 5000,
		// The config property is optional.
		// If no config is set, an example calendar is shown.
		// See 'Configuration options' for more information.

		feeds: [
			{
				title: "NU",
				url: "http://www.nu.nl/rss/Algemeen",
			},
			{
				title: "RTE",
				url: "https://www.rte.ie/feeds/rss/?index=/news/&limit=20",
			},

// {
// title: "Leonidas",
// url: "https://twitrss.me/twitter_user_to_rss/?user=@RKSV_Leonidas",
// },
{
title: "Sky News",
url: "http://feeds.skynews.com/feeds/rss/world.xml",
},
// {
// title: "Rijnmond",
// url: "https://wwww.rijnmond.nl/rss",
// },
]
},
},

	{
    module: 'MMM-pages',
    config: {
            modules:
                [[ "MMM-NLDepartureTimes", "MMM-Todoist" ],
                 [ "nstreinen", "MMM-MyScoreboard" ]],
            fixed: ["updatenotification", "alert", "calendar", "weatherforecast", "MMM-ImagesPhotos", "MMM-Pages", "MMM-NowplayingOnSpotify", "MMM-rainfc", "MMM-Screencast", " MMM-MotionDetector", "MMM-MyGarbage", "clock", "currentweather", "MMM-page-indicator", "newsfeed", "MMM-OpenmapWeather",],
	rotationTime: 10000,
	homePage: 1,
	
    }
},

]

};

/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {module.exports = config;}

Hidden pages

Is it possible to define max pages to rotate and allow pages after that to only be shown if called by notifications.

Say if I only had one page '0' that only has the default clock and calendar modules then max_pages=1.
Only 1 page so no rotation but after that I can add 'hidden' pages.
Then 'hidden' page 1 would have Calendar-weekly, hidden page 2 would have CalendarExt that are cycled via a notification such as up/down/left/right.
Prob left/right to control your indicator and set page when pages > 1 so likely up/down to change what would be views for that page?

So the above would look something like:-

{
module: "MMM-pages",
config: {
modules:
[ [ [ "calendar", "compliments" ], [ 1, 2] ],
[ "MMM-CalendarWeek" ],
[ "MMM-CalendarExt" ]
],
fixed: [ "clock", "MMM-page-indicator" ],
animationTime: 4*1000,
rotationTime: 30*1000,
maxPages: 1,
viewNotifications: [ "Page_up", "Page_down" ]
}
}

return changed page number as a result of PAGE_INCREMENT

I noticed module has no feature to emit notifications about current page sequence to other modules.

Would be nice that module return changed page number as a result of PAGE_INCREMENT / DECREMENT so, in other words: recognize which page the Mirror is at that moment because (in my mirror) CalendarExt2 cannot know what scene to show.
If thats implemented I can sync the scene to that number easily and use different scenes for my purpose without worries about page number.

Im trying to get MMM-pages, MMM-Calendarext2, MMM-AlexaControl, MMM-PageIndicator & MMM-GroveGestures working together and have several problems as I want to send to calendarext2 a notification to change the view but without changing the page. With the help of MMM-NotificationTrigger I can fire QUERY_PAGE_NUMBER but can't accomplish the result I want.

Sorry to open an issue here but don't know if you follow magicmirror forums...Many modules involved and cannot find a clear way to deal with.

Thanks in advance!

git pull: Please tell me who you are

Hi Eddie,

sorry for asking you again.
I just wanted to pull the latest version of MMM-pages entering the command git pull.
However the console is asking who I am.

*** Please tell me who you are.

Run

git config --global user.email "[email protected]"
git config --global user.name "Your Name"

to set your account's default identity.
Omit --global to set the identity only in this repository.

I tried to pull another modul, which works fine. So maybe it is a bug?

Thanks again.
McNose

Timer to change pages?

How about adding the ability to automatically rotate through pages every xx seconds, in addition to reacting to notifications?
I know it can be done with Carousel, but this seems cleaner.

modules of different sizes on the sides

Hello
I noticed that some modules have different sizes on pages 2 and 3. How or where do I have to change what so that my modules have a uniform size on the pages.

Error in pm2 logs and all modules on default page

Describe the bug
After updating the module the single pages (in my case 4) dont exist, instead the modules are all show on default page (page one).

To Reproduce
Steps to reproduce the behavior:
Update the module and restart mm

Expected behavior

Screenshots

Please fill out the following information;

  • Node version: 9.11.2
  • Have you updated to the latest MagicMirror core? no
  • Please post the relevant part of your config file here:
{
			module: 'MMM-pages',
			config: {
					modules:
						[["MMM-MyCalendar", "MMM-GoogleMapsTraffic"],//Seite A
						 ["MagicMirror-FootballLeagues", "MMM-PublicTransportHafas"],//Seite T
						 ["MMM-WeeklySchedule"],//Seite L
						 ["updatenotification", "MMM-SystemStats"]],//Seite Status
					excludes: ["alert", "clock", 'MMM-forecast-io', "newsfeed", "MMM-page-indicator","MMM-Navigate","MMM-Podcast","MMM-WatchDog","MMM-ModuleScheduler","MMM-PIR-Sensor","MMM-Remote-Control"],
					}
		},
  • Please post any errors you see about MMM-Pages in the console (Hit F12 > Console when the Magic Mirror window is focused), or write None if there aren't any:
    PM2 logs
    /home/pi/.pm2/logs/mm-error-0.log last 15 lines:
    0|mm | ERROR! Could not validate main module js file.
    0|mm | /home/pi/MagicMirror/modules/MMM-pages/MMM-pages.js:162
    0|mm | )); this.config.animationTime / 2);
    0|mm | ^
    0|mm | SyntaxError: Unexpected token )

Greetings AxLED

MMM-Pages not working with MMM-Weather-Now and MMM-3Day-Forecast

Describe the bug*
I have 5 pages and they work OK, I want to exclude: "MMM-Weather-Now" and "MMM-3Day-Forecast" but as soon as I activate the MMM-Pages module these 2 dissapear even if I add them to the exclude list.

I checked that they work before making the MMM-pages module active.

To Reproduce
just add these 2 modules to a config file where the pages module is avµctive an you cannot get them to show.

Expected behavior
They should appear as if they do without the pages module active.

Screenshots
If applicable, add screenshots to help explain your problem. If you believe you have aptly described your issue in words, feel free to ignore this section.

Please fill out the following information;

  • Node version: V9.11.2
  • Have you updated to the latest MagicMirror core? [yes]
  • Please post the relevant part of your config file here:
modules: [
		 {
		        module: "MMM-pages",
		        config: {
		                modules:
		                    [[ "compliments", ],
				     [ "newsfeed" ],
				     [ "DailyXKCD" ],
				     [ "MMM-DailyDilbert" ],
		                     [ "MMM-quote-of-the-day" ]],
		                excludes: ["clock","MMM-OnScreenMenu", "MMM-Weather-Now", "MMM-3Day-Forecast", "MMM-page-indicator"],
				animationTime: 2000,
				rotationTime: 20000,
				delayTime: 200000
		    	}
                },
		{
		        module: "MMM-page-indicator",
		        position: 'bottom_bar',
		        config: {
		            pages: 5,
		        }
    		},
		{
			module: "clock",
			position: "top_left",
			config: {
				timeFormat: 24,
				displaySeconds: true,
				displayType: "both",
				timezone: "Etc/GMT-2"
			}
		},
		{
	            	module: "MMM-OnScreenMenu",
	            	position: "bottom_left",
	            	config: {
	                	touchMode: false,
	                	enableKeyboard: true
	            	}
    		},
		{
			module: "MMM-Weather-Now",
			position: "top_left",
			config: {
				api_key:    "xxxxxxxxxxxxxxxx",
				lat:	    51.054342,
				lon:	    3.717424,
				units:	    "M",
				lang:	    "en",
				interval:   900000
			}
		},
... and so on
  • Please post any errors you see about MMM-Pages in the console (Hit F12 > Console when the Magic Mirror window is focused), or write None if there aren't any:

Additional context
I think somehow the opacity of these modules is staying at 0?

How to use touchscreen to slide?

I want this module to slide on the touch screen, I have an IR Frame, but I don't know what to do right.
Plz help me, thank you so much!!

MMM-CalendarExt2 Page (Scene) Change Notification

When running MMM-pages + MMM-CalendarExt2 and rotationHomePage ≠ 0....when the timeout occurs and MM returns to the first page, but MMM-CalendarExt2 remains on the same calendar. It seems MMM-CalendarExt2 may need the notification "changeSceneByName" with a payload of...well, I'm not sure but the code is here at line 20.
"CALEXT2_SCENE_CHANGE" : { exec: (payload, sender) => { if (payload.type && payload.type == "id") { return "changeSceneById" } else if (payload.type && payload.type == "name") { return "changeSceneByName" } else { return null } },

Slide animation in/out

This was raised on behalf of an email. A Feature Request was made to add sliding animations when one slides left or right, instead of the current fade out animation.

Unfortunately, my attempts have failed. Partial work has been done in the slide-animation branch, and requires add this to your custom.css:

body div {
  transition: transform 1s !important;
}

It's probably possible with more CSS work, but the MagicMirror framework really doesn't like you messing around with other module's css. You need to directly bypass the MagicMirror framework to add classes to other modules, and then overriding transition effects.

PR highly desired.

Doesn't work with MMM-TFL Arrivals

Hello

The MMM-TFL-Arrivals doesn't show anything when run in MMM-Pages.
When run without MMM-Pages it works fine.

The config looks like this:

modules: [
	
            {module: 'MMM-pages',
            config: {
            modules:
                [[ "MMM-TFL-Arrivals"],
                 [ ""],
                 [ ""],
                 [ ""],
                 [ ""],
                 [ ""],
                 [  ""],
                 [ "" ],                     
                 [ ""],
                 [ ""]],
            fixed: ["MMM-page-indicator"],
            rotationTime:"0",
            }
            },

              {
	  module: 'MMM-TFL-Arrivals',
          position: 'top_left',
          header: "Bus Arrivals",
               config: {
	       app_id: "", //keys removed,
	       app_key: "", //Keys removed
	       naptanId: "", // StopPoint id removed
	       animationSpeed: 1000,
	       fade: true,
	       fadePoint: 0.25, // Start on 1/4th of the list.
	       limit: 5,
	       initialLoadDelay: 5,
	       color: true,
	       debug: false
	},
	
		}

]

Any idea what is causing the blank/black screen with MMM-Pages?

Thanks in advance.

[feature request] Have the option to start (some) "fixed" modules hidden

Is your feature request related to a problem? Why do you want this feature?
I am using MMM-pages with MMM-Touch on a touch display and have a heavy touch related configuration setup f.e. to activate a "screensaver" mode when sliding down (which hides a lot of "fixed" modules and shows others (which are paused on start-up)

Describe the solution you'd like
I am thinking about a fixedStartHidden array which uses the already implemented "pause / hiding" feature (used for modules on "other" pages) to also hide modules which are present in both arrays: fixed and fixedStartHidden (or however you want to name it :) ). With this feature I can have a "startHidden" option for other third party modules without the need to modify each and every one of them.

Additional context
Wanted to get your opinion about this before creating any PR.

how to change pages?

I'm using GroveGesture Sensor(PAJ7620u2) MMM-GroveGestures
how to use change pages?

Issue with PAGE_INCREMENT / PAGE_DECREMENT

You can also just send PAGE_INCREMENT or PAGE_DECREMENT without any payloads (or with, but it will be ignored) to have the module change the displayed page by one.

I appear to be seeing an issue with the module; just checking if anyone else has seen this and has any ideas what I might be doing wrong or if it is a genuine bug/issue.

I have MMM-pages installed on my mirror along with MMM-page-indicator and MMM-remote-control; from my OpenHab installation I have commands that send either:

http//:[my_mirror_ip]:8080/remote?action=NOTIFICATION&notification=PAGE_DECREMENT&payload=1
or
http//:[my_mirror_ip]:8080/remote?action=NOTIFICATION&notification=PAGE_INCREMENT&payload=1

This is then received by MMM-remote-control and the notification is then sent on.

I currently have 4 pages setup on my mirror.

If I send an INCREMENT command it shows the next page correctly, sending another shows the next page correctly, this works all the way to the 4th page. Sending another INCREMENT then shows page 1 again, as would be expected.

However sending a DECREMENT command appears to not decrement the page correctly - The page displayed appears to be the next incremented page, but the page indicator displays as if the page has moved back one correctly.

Page-Duration

As an idea - for some users it might be helpful to adjust individuall duration time for each page.
This would have the advantage, that pages with more data can rest longer, where other pages with less information can be slided faster.
Furthermore the user would have the possibility to give a page the duration "0" seconds, if he doesn't wants to show the module although it should be loaded and operationg in the background (e.g. MPlayerRadio).
Would this new feature be possible? I would appreciate it very :-)

Changing pages doesn't work - bugs in the console

Thank you for the great module.
Unfortunately, I have a problem with page switching.

My config:

{
        module: 'MMM-pages',
        config: {
                modules:
                    [[ "weatherforecast", "newsfeed"],
                     [ "calendar", "compliments" ]],
                fixed: [],
				homePage: 0,
        }
    },

When I trigger the page change command I get errors and the page does not change.
http://192.168.2.200:8080/api/notification/PAGE_CHANGED?payload=1

image

Pause rotation not working

I am trying to use your module, but I am not able to pause rotation. I have tried to send notifications from the module Touch_Swipe, or from Remote-Control, but it does not work. Basically the notification that it send is:
self.sendNotification('PAUSE_ROTATION', '')

My setup is:
{
module: 'MMM-pages',
config: {
modules:
[
["MMM-CalendarExt2"],
["MMM-Trello"],
["MMM-EveryNews"],
["MMM-Weather"],
["MMM-Fuel","MMM-DWD-WarnWeather","MMM-COVID19-AMPEL"] ],
fixed: ["clock","MMM-TouchSwipe","MMM-OnScreenMenu","MMM-BurnIn",'MMM-Remote-Control'],
hiddenPages: {
"screenSaver": [ "clock" ],
"admin": [ "MMM-OnScreenMenu" ,"MMM-TouchSwipe","MMM-BurnIn",'MMM-Remote-Control'],
},
homePage:0,
rotationHomePage:0,
rotationTime: 1000 * 60 * .25
}
},

Thank you for your help!

Button input to switch pages

Hey dude, I have the fixed modules and everything I want set up but I can't for the life of me figure out how to get MMM-Buttons to make it switch. I noticed there needs to be a page number in the payload but I really just want to switch between my fixed modules and then push the button and it shows all of them. Any advice?

Using MMM-Buttons to increment and decrement makes MMM-Pages send a whole lot of increment notifications by itself

Describe the bug
I'm using MMM-Buttons to send an increment or decrement page notification, wich works. But after the rotationtime the MMM-Pages module starts to generate increment notifications by itself (checked in console). Seemingly random. The buttons keep working during this.

When not using the MMM-Buttons module this behavior is not present.

I am also using your Page indicator module

To Reproduce
use the MMM-Buttons module to send increment and decrement notifications to the MMM-Pages module and wait until the rotationtime has elapsed.

Expected behavior
MMM-Pages should not generate increment notifications by itself

Pause & Resume Rotation from notifications

It would be nice to add the ability to pause / resume page rotation from notifications.
ie. pause & resume rotation from a gesture or voice command
I do not know if it is very difficult to implement tho.

Thanks for such a nice module

Change page with swipe

Hello,

i want change the pages with a swipe but i don't know how. i don't know this about send.notification or stuff like this. i don't know where i have to write down and what i have to write down. u can help me with some examples?

thanks

Current weather

current weather will not load on page one no settings changed just default

PAGE_DECREMENT with 'payload: null,' not working as expected

Describe the bug
I tried to use PAGE_DECREMENT with 'payload: null,' activated by a GroveGesture but it didn't work. I had to use 'payload: 1,' for it to operate correctly. PAGE_INCREMENT works well with 'payload: null,'.

The problem seems to be the minus right before 'payload' in the following part of MMM-pages.js

      case 'PAGE_DECREMENT':
        Log.log('[Pages]: received a notification to decrement pages!');
        this.changePageBy(-payload, -1);

I changed the last line to this.changePageBy(-(payload, 1)); and it works for me with payload null.

To Reproduce
Steps to reproduce the behavior:

  1. Try to use PAGE_DECREMENT with 'payload: null,'

Expected behavior
Navigate to previous page.

Please fill out the following information;

  • Node version: 10.16.1
  • Have you updated to the latest MagicMirror core? yes
  • Please post the relevant part of your config file here:
        "LEFT": {
          notificationExec: {
            notification: "PAGE_DECREMENT",
            payload: null,
          }
        },

Additional context

Weather module

Describe the bug
A clear and concise description of what the bug is.
Every time I add my current weather module to the first page it would get stuck in the loading page. However if I remove it and move it to the second page it will load.
To Reproduce
Steps to reproduce the behavior:
(Please paste any information on reproducing the issue, for example:)

Add current weather module to the config file.
Add the module name to the first row for page one. (stuck on loading)
Remove from first page and add to the second and it loads.

Expected behavior
A clear and concise description of what you expected to happen.

The current weather to display on the top right.

Screenshots
If applicable, add screenshots to help explain your problem. If you believe you
have aptly described your issue in words, feel free to ignore/delete this section.
Don't have any screenshots right now but will try to add some once I get some.
Please fill out the following information;

  • Node version: [This can be obtained by running node --version]
    v10.21.0
  • Have you updated to the latest MagicMirror core? [yes/no]
    Yes
  • Please post the relevant part of your config file here:
(Paste the part of the config file here)
{
    module: 'MMM-pages',
    config: {
            modules:
                [
                 [ ],
                 [ "newsfeed", "currentweather"],
                 [ "calendar", "weatherforecast","MMM-COVID19","MMM-PrayerTime"],
                ],
            fixed: ["clock", "MMM-NowPlayingOnSpotify", "MMM-page-indicator"],
        }
    },
  • Please post any errors you see about MMM-Pages in the console (Hit F12 > Console when the Magic Mirror window is focused), or write None if there aren't any:

None
Additional context
Add any other context about the problem here.

Again, I'd like to apologise for my previous post. I should have read through. Sorry.

[BUG] Modules disapper from pages after rotationHomePage times out

Describe the bug
Modules disappear from pages after rotationHomePage times out and they don't come back. Pages remain blank. This happens since the latest update of MMM-pages. Before the update everything was fine.

To Reproduce
Steps to reproduce the behavior:
(Please paste any information on reproducing the issue, for example:)

  1. Boot into MM. The pages are shown normally with all modules
  2. Wait for the time that is adjusted in config.js for rotationHomePage (in my case 130000ms)
  3. The page (and all other pages) go blank, only the page indicators remain visible
  4. The pages remain blank until I reboot MM.

Expected behavior
After rotationHomePage times out the defined homPage should be displayed with its assigned modules

Screenshots
If applicable, add screenshots to help explain your problem. If you believe you
have aptly described your issue in words, feel free to ignore/delete this section.

Please fill out the following information;

  • Node version: 10.23.0
  • Have you updated to the latest MagicMirror core? yes, 2.13.0
  • Please post the relevant part of your config file here:
			module: 'MMM-pages',
			disabled: false,
			config: {
				modules:
					[

						// Page 0 -- Magic Clock
						["MMM-TextClock", "newsfeed"],
						// Page 1 -- Hauptseite
						["clock", "newsfeed", "MMM-MyCalendar", "MMM-withings", "MMM-DarkSkyForecast", "MMM-RAIN-MAP", "MMM-DWD-WarnWeather", "MMM-Sonos", "MMM-PublicTransportHafas", "MMM-MyScoreboard", "MMM-COVID19-AMPEL"],
						// Page 2 -- SmartHome
						["clock", "MMM-Netatmo", "MMM-Tools", "mmm-hue-lights", "MMM-Homematic"],
						// Page 3
						["octomirror-module"],
					],
				fixed: ["alert", "updatenotification", "MMM-page-indicator", "MMM-NewPIR"],

				animationTime: 500,
				rotationHomePage: 130000,
				homePage: 0,
			}
		},
  • Please post any errors you see about MMM-Pages in the console (Hit F12 > Console when the Magic Mirror window is focused), or write None if there aren't any:
    see attached screenshot
    Bildschirmfoto 2020-11-06 um 10 54 37
    Errors in pm2 logs: None

Why not include page indicator?

Hi Edward,
Your module seem very simple to use, and promising as a low-load replacement of the Carousel.
However, why did you not include the page indicators directly in this module?

doesn't work with 'MMM-Netatmo-Thermostat'

Hi,

If i add 'MMM-Netatmo-Thermostat' to config.js, 'MMM-Pages' no longer changes page.

Specifically, I see 'Indicator' changed the page, but the display stays on the page '1', nothing changes on the other pages.

No error on 'npm start'

Node version : 9.11.2

Page one hidden after Page_Increment / decrement

Hi Ed,

seems like I found another issue. Guess it happens after your very last update, because I didnt see it when I testet the previous one.

I have got 2 pages and the page indicator.
When I start the mirror I see page one as defined.
I switch the page using page_increment or decrement.
I see page two as defined.
I use page_increment / decrement again.
Page one is black except the modules which are excluded by MMM-pages.

Any idea about that?
Please let me know if you need any further information.

Thanks.

Where to put this.sendNotification

Hi there,

I'm just a newbie trying to use your MMM-Pages and MMM-page indicator but I'm stuck!
I did the git pull..... changed the config.js file but were should the "this.sendNotification("PAGE_CHANGED", 2);" go?? In your discribtion it is only mentioned that this must be added to "my code".
But I don't understand what file you mean by that. Perhaps you could ad an example code to the discription were we can see were this piece of code must go?

Hope you can help me.

With kind regards,
Mike Wellink
The Netherlands

typo in line 75 of MMM-pages.js

Hi, is it possible that there is a typo in line 75?
shouldnt it be (mod)
this.curPage = this.mod(this.curPage - 1, this.config.modules.length);
instead of (mode)
this.curPage = this.mode(this.curPage - 1, this.config.modules.length);
?
Regard
AxLED

Page refresh for every switch

I'm going to ignore the bug report template for now as I am not sure if this is a bug or enhancement or neither. Let me know if you prefer me to ask it differently.

I have setup MMM-Pages to have 2 pages -- the first page has my static stuff (clock, calendar, etc...) and a 2nd page loads the MMM-iFrame-Ping module which loads a URL from my weather station (see https://www.reddit.com/r/raspberry_pi/comments/il03rk/i_made_weather_station_app_and_designed_it_for_a/) as the only item on the 2nd page.

This all works but it appears that when the pages change either MMM-Pages or MMM-iFrame-Ping is actually re-rendering the URL from the weather station. Because the weather station uses external API's to build the page there is a limit on the number of times these can be called during a hour/day and I do not wish to exceed that. I can see that when using tcpdump and looking for outgoing calls to rainviewer.com a call is made everytime MMM-Pages switches to that page.

Can you confirm if MMM-Pages is doing a reload of the page or do you think this may be related to the iFramePing module?

How do i actually change pages

Hi edward, i am currently doing this magic mirror modules as a project for my internship, however i am currently stuck at creating pages and i would also like to make new pages for more modules to appear. PS, i am quite bad a programming thus when i read the page indicator modules, i cant really understand how do i configure it into the js file, below is my config.js coding

/* Magic Mirror Config Sample
 *
 * By Michael Teeuw http://michaelteeuw.nl
 * MIT Licensed.
 *
 * For more information how you can configurate this file
 * See https://github.com/MichMich/MagicMirror#configuration
 *
 */

var config = {
        address: "localhost", // Address to listen on, can be:
                              // - "localhost", "127.0.0.1", "::1" to listen
on loopback interface
                              // - another specific IPv4/6 to listen on a
specific interface
                              // - "", "0.0.0.0", "::" to listen on any interface
                              // Default, when address config is left out, is
"localhost"
        port: 8080,
        ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], // Set [] to
allow all IP addresses
                                                               // or add a
specific IPv4 of 192.168.1.5 :
                                                               //
["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.1.5"],
                                                               // or IPv4
range of 192.168.3.0 --> 192.168.3.15 use CIDR format :
                                                               //
["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.3.0/28"],

        language: "en",
        timeFormat: 24,
        units: "metric",

        modules: [


{
    module: 'MMM-LICE',
    position: 'bottom_right',                 // Best in left, center,
or right regions
    config: {
                accessKey: "xxxxx", // Free account & API
Access Key at currencylayer.com
                source: "USD",                    // USD unless you upgrade from free account
                symbols: "AUD,CHF,EUR,GBP",       // Currency symbols
                useHeader: false,
                header: "Money Exchange",
                maxWidth: "300px",
    }
},
{
    module: 'MMM-OnScreenMenu',
    position: 'bottom_left',
    config: {
        touchMode: true,
        menuItems: {
        monitorOff: { title: "Turn Off Monitor", icon: "television",
source: "SERVER" },
        restart: { title: "Restart MagicMirror", icon: "recycle",
source: "ALL" },
        refresh: { title: "Refresh MagicMirror", icon: "refresh",
source: "LOCAL" },
        moduleHide1: { title: "Hide Clock", icon: "minus-square", name: "clock" },
        moduleShow1: { title: "Show Clock", icon: "plus-square", name: "clock" },
        reboot: { title: "Reboot", icon: "spinner", source: "ALL" },
        shutdown: { title: "Shutdown", icon: "power-off", source: "ALL" },
        },
        enableKeyboard: true,
    }
},




        {
                        module: "alert",
                },
                {
                        module: "updatenotification",
                        position: "top_bar"
                },
                {
                        module: "clock",
                        position: "top_left"
                },
                {
                        module: "calendar",
                        header: "US Holidays",
                        position: "top_left",
                        config: {
                                calendars: [
                                        {
                                                symbol: "calendar-check-o ",
                                                url: "webcal://www.calendarlabs.com/templates/ical/US-Holidays.ics"
                                        }
                                ]
                        }
                },
                {
                        module: "compliments",
                        position: "lower_third"
                },
                {
                        module: "currentweather",
                        position: "top_right",
                        config: {
                                location: "Republic of Singapore",
                                locationID: "1880251",  //ID from
http://bulk.openweathermap.org/sample/; unzip the gz file and find
your city
                                appid: "xxxxx"
                        }
                },

                {
                        module: "newsfeed",
                        position: "bottom_bar",
                        config: {
                                feeds: [
                                        {
                                                title: "New York Times",
                                                url: "http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml"
                                        }
                                ],
                                showSourceTitle: true,
                                showPublishDate: true
                        }
                },

                {
                      module: 'MMM-pages',
                      config:
                        {
                        modules:
                        [["weatherforecast", "newsfeed", "MMM-LICE"]
                        ["calendar", "compliments"]],
                        excludes:["MMM-OnScreenMenu", "clock", "currentweather",
"MMM-page-indicator"],

                        }

                       },
                       {
                        module: 'MMM-page-indicator',
                        position: 'bottom_bar',
                        config:{
                        pages: 2,
                        }

                        },

        ]



};

/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {module.exports = config;}

Bug after npm install i get Unable to find electron's version number, either install it or specify an explicit version

Describe the bug
after npminstall inside ~/MagicMirror/modules/MMM-Swipe
i get this errors

pi@smartmirror:~/MagicMirror/modules/MMM-Swipe $ npm install

[email protected] postinstall /home/pi/MagicMirror/modules/MMM-Swipe
electron-rebuild -e ../../node_modules/electron-prebuilt

An unhandled error occurred inside electron-rebuild
Unable to find electron's version number, either install it or specify an explicit version

Error: Unable to find electron's version number, either install it or specify an explicit version
at /home/pi/MagicMirror/modules/MMM-Swipe/node_modules/electron-rebuild/lib/src/cli.js:87:19
at Generator.next ()
at fulfilled (/home/pi/MagicMirror/modules/MMM-Swipe/node_modules/electron-rebuild/lib/src/cli.js:6:58)
npm ERR! code ELIFECYCLE
npm ERR! errno 255
npm ERR! [email protected] postinstall: electron-rebuild -e ../../node_modules/electron-prebuilt
npm ERR! Exit status 255
npm ERR!
npm ERR! Failed at the [email protected] postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2020-09-26T13_44_20_466Z-debug.log

To Reproduce
Steps to reproduce the behavior:
(Please paste any information on reproducing the issue, for example:)

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem. If you believe you
have aptly described your issue in words, feel free to ignore/delete this section.

Please fill out the following information;

  • Node version: [This can be obtained by running node --version]
    v10.22.1
  • Have you updated to the latest MagicMirror core? [yes/no] yes
  • Please post the relevant part of your config file here:
(Paste the part of the config file here)
  • Please post any errors you see about MMM-Pages in the console (Hit F12 > Console when the Magic Mirror window is focused), or write None if there aren't any:

Additional context
Add any other context about the problem here.

Version:
pi@smartmirror:/MagicMirror/modules/MMM-Swipe $ python3 --version
Python 3.7.3
pi@smartmirror:
/MagicMirror/modules/MMM-Swipe $ cat /etc/os-release
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"

Using a module multiple times

I just wonder, maybe this isn't a feature request in first place and I just missed something.

Eg. I have two pages
sport
work

I need my sport events on the sport page and the work events on the work page.

How to configure MMM-pages to show up two different calendar sessions, but both with the same module?

I also want to use two instances of MMM-BackgroundSlideshow, so on the sport page it is sliding through sport pictures and on work page it is sliding work motivation pictures or whatsoever...

Is this module able to get notification from a python script

After tons of research and trying the modules that already exist, i havent able to find any module that works well for using ultrasonic sensors to detect swiping motion. so i am thinking, if i can make a python script that detects a swiping motion, am i able to use that to turn pages on the magicmirror?
so if i have something like this

def swiper():
  #code here to detect swipe
  if leftSwipe:
    #send a notification to pages to go left
  if rightSwipe:
    #send a notification to pages to go right

Can the pages module accept notification from a outside source like a python script?

return to first page only if current page isn't the first page without loop

Hello, first of all thank you for your great job! I'm not a developer, i searched a way to Return to first page after a delimited time, but without the automatic loop option of your module.

i have a first page with generic information, and some other page with confidential information.
i manually change page with alexa and want the Mirror automatically return to the first page after 30 second.

hi resolved my problem by modifying your JS but i'm sure there is a more "cleanly" method. Here is what i did :

Sorry for my english :-\

regards
Kevin

mmm-pages do not work with mmm-traffic

hi, i have installed mmm-pages and mmm-traffic. Without pages this modul works o.k., but when i install pages the traffic module doesn‘t show :-(

The same problem is coming with the MMM-OpenWebWeather. Her you can only see „Load“ but the module does‘t show with MMM-pages.

Here is my code in the config.js

{ module: "MMM-pages", config: { modules: [[ "MMM-SoccerLiveScore" ], [ "MMM-COVID19-AMPEL" ], [ "MMM-Formula1" ]], fixed: [ "clock" , "MMM-OpenmapWeather" , "weatherforecast" , "MMM-PublicTransportHafas" , "newsfeed" , "calendar" , "MMM-Fuel", "MMM-Tankerkoenig" , "MMM-ioBroker" , "MMM-Traffic" ], rotationTime: 120000, } },

Is there anyone who can help me about the mistake?

Thanks

Here is the magicmirro forum link

https://forum.magicmirror.builders/topic/14071/not-all-modules-are-displaying-on-the-tv/22?page=3

Config Request: Set custom default page

Is your feature request related to a problem? Please describe.
I'm using GroveGestures to send a notification to increase or decrease page numbers to Pages, and I'd like to start out on 'Page 2' so I can go left or right from 'home'.

Describe the solution you'd like
A config option to set the default page to whichever page I like.

Describe alternatives you've considered
None really, :s

Additional context
thanks man! awesome Module...

Switching Pages with MMM-ModuleScheduler leads to blank page

Hi,

I'm trying to switch the pages with ModuleScheduler. But it doesn't change the page, it just "leaves" the pages (no page highlighted in page indicator, no page shown). Any hints whats wrong with my config.js?

{
    module: 'MMM-ModuleScheduler',
    config: {
        notification_schedule: [{
                notification: 'PAGE_CHANGED',
                schedule: '0 7 * * 1-5',
                payload: {
                    type: "notification",
                    message: 0
                }
            },
            {
                notification: 'PAGE_CHANGED',
                schedule: '30 5 * * 1-5',
                payload: {
                    type: "notification",
                    messsage: 1
                }
            }
        ]
    }
}

Regards
Jan

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.