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

    Posts

    Recent Best Controversial
    • RE: Display waste bins in color

      @kusselin Sorry was occupied with something. The symbol is optional, if you do not provide it then it will take the default icon.
      Below is my config and output, Notice the new year’s day.

      customEvents: [
      	 {
      		"keyword": "Christmas Day",
      		"symbol": "calendar-icon-christmas",
      		"color": "red"
      	 },
      	 {
      		"keyword": "New Year's Day",
      		"color": "yellow"
      	 },
      	 {
      		"keyword": "Easter Sunday",
      		"symbol": "calendar-icon-easter",
      		"color": "blue"
      	 }
      	]
      
      2020-12-21-22-54-04-Clipboard
      posted in Custom CSS
      A
      ashishtank
    • RE: Force a module refresh - not the entire page

      @majdzik84 Good to know ! :)

      posted in Requests
      A
      ashishtank
    • RE: Force a module refresh - not the entire page

      @majdzik84 Okay, not sure why it is not listing the action. can you try below once ? it will send notification to all the modules including HA module and it should refresh the module. this is based on Remote control documentation https://github.com/Jopyth/MMM-Remote-Control/blob/master/API/README.md

      http://192.168.2.200:8080/api/notification/REFRESHHOMEASSISTANT

      posted in Requests
      A
      ashishtank
    • RE: Force a module refresh - not the entire page

      @majdzik84 said in Force a module refresh - not the entire page:

      {“success”:false,“message”:“Module Name or Identifier Not Found!”}

      • Did you added the code in MMM-homeassistant-sensors.js ?
      • Can you try http://192.168.2.200:8080/api/module/homeassistantsensors/refreshhomeassistant url ? (I have removed the - from home assistant sensors)
        for more details about module and it’s action check https://github.com/Jopyth/MMM-Remote-Control/tree/master/API
      posted in Requests
      A
      ashishtank
    • RE: Force a module refresh - not the entire page

      @majdzik84 If I understood you correctly, you want to send message to Magic Mirror when sensor value change in home assistant and it should refresh the MMM-HomeAssistant-Sensors module, so you see updated value of sensor over there ?

      It should be doable with MMM-Remove-control same way as you are sending alert. I have not installed the remote control module and MMM-HomeAssistant-Sensors so can’t test the code my self but you can do below.

      • Add below code in MMM-homeassistant-sensors.js
      notificationReceived: function (notification, payload, sender) {
      		if (notification === "REFRESHHOMEASSISTANT") {
      			this.getStats();
      		} 
      },
      
      • Do not forget the , after } in last line else it will break the module
      • Restart the mirror
      • From your browser open http://192.168.2.200:8080/api/module/MMM-homeassistant-sensors or http://192.168.2.200:8080/api/module/homeassistantsensors if first url does not work
      • If you see REFRESHHOMEASSISTANT in response then remote control knows new action on HA module
      • Now you can send command from HA to refresh the module using http://192.168.2.200:8080/api/module/homeassistantsensors/refreshhomeassistant (url should be in lowercase and also MMM- and - are removed in api path)

      As I can not test it and things I have suggested above are based on my code review of both the modules. you might need to adjust one or more things. but in theory it should work.

      Let me know how (or if) it works.

      posted in Requests
      A
      ashishtank
    • RE: MMM-MyWastePickup

      @MyMirror Changing color is easier here using css

      dfe1c49e-64a7-4d42-bffe-668ceae6adeb-image.png

      you can create similar class in custom.css and change the value of fill property to what you want.


      But changing icon itself will be difficult as here author is using svg image sprite and not separate icon files.
      you will need to change below file and replace the icon with the one you wanted (also with correct size)

      b4ea4e83-7847-4699-be7e-3eb73115b410-image.png

      More on image sprite
      https://css-tricks.com/svg-sprites-use-better-icon-fonts/

      posted in Troubleshooting
      A
      ashishtank
    • RE: Damn Elves Hacked My Mirror!!

      @lucallmon Try with some candies first :)

      posted in Show your Mirror
      A
      ashishtank
    • RE: Force a module refresh - not the entire page

      @majdzik84 You can call updatedom method of the target module to refresh that specific module, or if that module have notification refresh then can send notification. Check below documentation for update dom method of modules
      https://docs.magicmirror.builders/development/core-module-file.html#this-updatedom-speed

      posted in Requests
      A
      ashishtank
    • RE: new update/upgrade script, ready for testing

      @sdetweil : Thank you for the great installer script ! it worked well on Raspberry Pi Zero W. I had issue with electron and dependencies but it did the job :)

      posted in General Discussion
      A
      ashishtank
    • RE: How to add modules. For absolute beginners.

      @fsne04 Here it checks for the position value (edited my answer above).

      7c8840e0-041d-40fb-bf8c-2bf5e47bef31-image.png

      8e2d4b3d-f498-4d22-9d7b-3c3649c4718b-image.png

      posted in Troubleshooting
      A
      ashishtank
    • 1 / 1