shbatm / MMM-Carousel

Displays a single magic mirror module at a time, rotating through the list of configured modules in a carousel-like fashion.
MIT License
40 stars 13 forks source link

cannot swap slides unless using timer #18

Closed doug-doug closed 5 years ago

doug-doug commented 5 years ago

When I add Carousel to my working configuration and use slides on a timer, it all works perfect. The problem is when I try to trigger slide changes using my keyboard - it will not change slides. i added KeyBindings and followed the ReadMe's. My end state is to use MMM-Navigate to control Carousel but i need to get Carousel working to advance my slides before I try to cross that bridge... (so if anyone can shortcut me there...)

Here is my code stub:

,modules: [{module: 'MMM-Remote-Control' // ,position: 'bottom_bar' } ,{module: 'MMM-Remote-Control-Repository'} ,{module: 'MMM-KeyBindings' ,config: { evdev: {enabled: false} ,enableNotifyServer: false ,enableMousetrap: true ,actions: [ {key: "ArrowLeft" ,state: "KEY_LONGPRESSED" ,notification: "CAROUSEL_PREVIOUS"} ,{key: "ArrowRight" ,state: "KEY_LONGPRESSED" ,notification: "CAROUSEL_NEXT"} ,{key: "Return" ,state: "KEY_LONGPRESSED" ,changeMode: "DEFAULT"} ]} } ,{module: 'MMM-Carousel' ,position: 'bottom_bar' // Only required to show navigation ,config: {mode: 'slides' ,transitionInterval: 0301000 ,slideTransitionSpeed: 1.51000 ,ignoreModules: ['MMM-Remote-Control', 'MMM-Remote-Control-Repository', 'MMM-KeyBindings' ,'alert', 'updatenotification', 'worldclock'] ,slides: [ // ---------------------------------- MORNING ------------------------------------ ['MMM-MyCalendar', 'calendar', 'MMM-DHT-Sensor', 'MMM-AirQuality', 'currentweather', 'weatherforecast', 'MMM-DailyDilbert', 'calendar_monthly', 'newsfeed', 'MMM-LICE'] // ----------------------------------- SOCIAL ------------------------------------ ,['MMM-Events', 'calendar', 'MMM-AirQuality', 'currentweather', 'weatherforecast', 'MMM-EARTH', 'calendar_monthly', 'MMM-WorldTides', 'MMM-Lunartic'] // ----------------------------------- SPACE ------------------------------------- ,['MMM-NEO', 'MMM-NASA', 'MMM-Launch', 'MMM-Globe', 'mmm-moon-phases'] // ----------------------------------- SYSTEM ------------------------------------ ,['MMM-ip', 'mmm-systemtemperature', 'MMM-connection-status', 'MMM-SystemStats', 'MMM-NetworkScanner', 'MMM-URHere'] ] ,showPageIndicators: true ,showPageControls: true ,keyBindings: {enabled: true ,map: {NextSlide: "ArrowRight" ,PrevSlide: "ArrowLeft" ,Slide0: "Home"} ,mode: "DEFAULT"} } } / ================================ top_bar ================================ */

jfisher446 commented 5 years ago

Same issue here. Key bindings seem not to function.

shbatm commented 5 years ago

@doug-doug: KeyBindings is build into this version of Carousel, and there was a recent change that was missed in the README, enableMousetrap was changed to enableKeyboard. Please try to update the MMM-KeyBindings section to:

,enableKeyboard: true
,actions: []

@jfisher446, Please post your config sections.

doug-doug commented 5 years ago

@shbatm: i had to reinstall MM and my modules to get this to work but the combo did the trick.

you have solved my issue. i will leave this open for you and @jfisher446 to carry on.

jfisher446 commented 5 years ago

I'm good, please close. I broke my config and won't be able to repair it for a bit. Thanks.