MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    1. Home
    2. Getinthegames
    3. Best
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.
    G
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 1
    • Posts 7
    • Groups 0

    Posts

    Recent Best Controversial
    • Switch Months - MMM-CalendarExt3 -

      I’ve made quite a progress to code my MagicMirror the way I want it to work, but I’m hitting a wall right now and need help.

      I’m trying to make a simple navigation for MMM-CalendarExt3 where PageUp and PageDown would switch to next and previous months.

      I use those buttons because I’ll be using a usb clicker that has those 2 buttons.

      I have no issues with the clicker itself, it works on the Raspberry Pi and show the proper input on websites like key-event-viewer.

      So far I’v tried with MMM-KeyBindings, but the only notification MM is recievinge is MMM-KeyBinding sent “KEY PRESS” no matter the button I press, even on a regular keyboard (not all button works thought, mostly arrows, enter, space etc… but not PageUp and PageDown).

      I can enable evdev to listen to my clicker and in the terminal, when magic mirror is running with KeyBindings, I can see “KEY_104 pressed” and "KEY_109 pressed " when I use the clicker on path /dev/input/event0

      But in my code, no matter what I put, it only sends MMM-KeyBindings sent “KEY PRESS”
      Here is what my code would look like
      {
      module: “MMM-KeyBindings”,
      config: {
      enableKeyboard: true,
      evdev: {
      enabled: true,
      eventPath: “/dev/input/event0”
      },
      keyBindings: [
      { key: “KEY_104”, notification: “CALENDAR_NEXT” },
      { key: “KEY_109”, notification: “CALENDAR_PREV” }
      ]
      }
      },
      (I tried with “PageUp” and “KEY_PAGEUP”. That last one is what I get with evtest on input 0)

      After 2 days, I decided to check a new avenue with MMM-Remote-Control.

      I managed to get further (kind of) and managed to get the right notification sent to the calendar throught curl commands and the API. Not sure yet how to make the clicker input commands throught, but the issue here lies in the actual notifications right now.

      I wanted to use CX3_MOVE_CALENDAR, but it did not do anything. It is deprecated and not working at all, but the deprecated CX3_SET_DATE does work, but it’ll be kind of hard to use it as it goes to a specific date.

      Tried with CX3_SET_CONFIG but this also seems to not change the month, no matther what monthIndex I send with it.

      I’m quite confused right now on the best approach. As of reference, my MM currently look like this and it’s the calandar on the left I’d like to be able to flip from month to month.

      dfcf719e-21df-4dc1-8c00-f817d66c3362-image.png

      posted in Troubleshooting
      G
      Getinthegames
    • 1 / 1