MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    Currency Exchange Rates?

    Scheduled Pinned Locked Moved Solved Requests
    22 Posts 8 Posters 18.4k Views 8 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • E Offline
      elmerito25
      last edited by yawns

      I am NOOB here. Was wondering if someone has developed a module that retrieves exchange rates base on the local currency?

      Thanks!

      1 Reply Last reply Reply Quote 0
      • F Offline
        foggy
        last edited by

        I would love to have this functionality as well.

        1 Reply Last reply Reply Quote 0
        • yawnsY Offline
          yawns Moderator
          last edited by

          @foggy @elmerito25
          Could you please let me know how the output should look like?
          The base work is done (except for some more error handling and code cleanup) but I’d like your thoughts on the output.

          F E 2 Replies Last reply Reply Quote 0
          • F Offline
            foggy @yawns
            last edited by

            @yawns

            Thank you for responding.

            I am away on business. Back on Friday and I will then comment.

            Best wishes.

            1 Reply Last reply Reply Quote 0
            • E Offline
              elmerito25 @yawns
              last edited by

              @yawns Maybe similar like this: 0_1480528611146_andorid2.jpg It would be nice to have a base currency and then list the exchange rates for major currencies (USD/GBP/EUR…). Maybe an array of currencies so users can pick and choose what currency exchange rates they want to show.

              Thanks in advance!

              1 Reply Last reply Reply Quote 0
              • CatoC Offline
                Cato Module Developer
                last edited by

                How many currencies are people really interested to follow on their mirror? 1? 3? 5? 10? More? This number would dictate the layout of the module.

                I’m considering a module for my self, but I basically just need 1 (THB/NOK).

                yawnsY 1 Reply Last reply Reply Quote 0
                • yawnsY Offline
                  yawns Moderator @Cato
                  last edited by

                  @Cato
                  Right, that’s my concern too. I don’t want to overload the mirrors space

                  Maybe I can add some logic to choose the layout based on the number of currencies chosen

                  E 1 Reply Last reply Reply Quote 0
                  • E Offline
                    elmerito25 @yawns
                    last edited by

                    @yawns Agreed. Maybe a maximum of 3 currencies?

                    1 Reply Last reply Reply Quote 0
                    • yawnsY Offline
                      yawns Moderator
                      last edited by yawns

                      all right everyone, I did some progress on the module. Please take a look at it and let me know your thoughts.

                      Features:

                      • ticker mode - displays all selected currencies in a marquee ticker, main use in my opinion is in bottom_bar or top_bar
                      • table mode - display all selected currencies in a table. Up to 8 currencies are split into 2 columns, anything above is split into 3 columns
                      • you can hide/show the curreny flag and the currency code/abbreviation
                      • you can display a custom header above the output to show your selected base currency and the date of the data

                      Question: Does anyone know if and how I could manipulate the original header to avoid the custom header thing and still display base currency and date?

                      One notice: data is provided by fixer.io which is updating their data once a day. There are other apis for currency rates but you cannot select your own base currency if you are on a free plan. Means you would have to pay for it

                      [card:yawnsde/MMM-CurrencyExchange]

                      F A 2 Replies Last reply Reply Quote 1
                      • F Offline
                        foggy @yawns
                        last edited by

                        @yawns Super job. Thank you. Works well.
                        Is it possible to define which currency is displayed first?

                        Just in case another newbie comes along. the last (,) comma is in the wrong place and should be moved to the end.

                        Best wishes.

                        1 Reply Last reply Reply Quote 0
                        • yawnsY Offline
                          yawns Moderator
                          last edited by

                          I guess I could add some sorting mechanism, maybe based on the array order.

                          Which comma exactly? I’m just on my smartphone, so I might oversee it

                          F 1 Reply Last reply Reply Quote 0
                          • F Offline
                            foggy @yawns
                            last edited by

                            @yawns The one on the penultimate line.
                            modules: [
                            {
                            module: ‘MMM-CurrencyExchange’,
                            position: ‘top_right’,
                            config: {
                            base: ‘EUR’,
                            symbols: [‘GBP’, ‘USD’]
                            },
                            }

                            1 Reply Last reply Reply Quote 0
                            • yawnsY Offline
                              yawns Moderator
                              last edited by

                              Thanks. Fixed!

                              1 Reply Last reply Reply Quote 0
                              • CatoC Offline
                                Cato Module Developer
                                last edited by

                                Great module - works perfectly!

                                I’m not sure if this is just me, but for some currencies I like to switch the base currency because that makes more sence to me.

                                Suggestion: make an array of base/currencies, like this:

                                currencies: [
                                      { base: 'NOK', symbol 'THB' },
                                      { base: 'EUD', symbol 'NOK' },
                                      { base: 'USD', symbol 'NOK' }
                                ]
                                

                                A little harder to configure, but much more flexible.

                                Again - not sure if this is for everyone… (?)

                                1 Reply Last reply Reply Quote 0
                                • yawnsY Offline
                                  yawns Moderator
                                  last edited by

                                  Nice idea!
                                  I’m at home on Wednesday, I guess I’ll find some time to look at this. Would require more api requests or more conversion and math.

                                  F 1 Reply Last reply Reply Quote 0
                                  • F Offline
                                    frog @yawns
                                    last edited by

                                    @yawns Hi,

                                    How often does this refresh? I’m getting no changes on my mirror even though I’m restarting it.

                                    1 Reply Last reply Reply Quote 0
                                    • yawnsY Offline
                                      yawns Moderator
                                      last edited by

                                      The api provider is http://fixer.io and updates once a day. If you check the website and click on the first code snippet it should unfold and show the latest update including exchange rates. Does this match with what you see on the mirror? Or is the data on your mirror older?
                                      You could enable the customHeader, then the update date is shown as retrieved from the api

                                      F E 2 Replies Last reply Reply Quote 0
                                      • F Offline
                                        frog @yawns
                                        last edited by

                                        @yawns thanks. The date says a day out I.e the 5th for today (the 6th). I wasn’t aware of only a daily update, so it must be working OK. Thanks

                                        1 Reply Last reply Reply Quote 0
                                        • E Offline
                                          elmerito25 @yawns
                                          last edited by

                                          @yawns Appreciate developing this module. Just added this to my “soon-to-be-completed” MM and looks good!

                                          1 Reply Last reply Reply Quote 0
                                          • A Offline
                                            AviY @yawns
                                            last edited by

                                            This post is deleted!
                                            1 Reply Last reply Reply Quote 0

                                            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                                            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                                            With your input, this post could be even better 💗

                                            Register Login
                                            • 1
                                            • 2
                                            • 1 / 2
                                            • First post
                                              Last post
                                            Enjoying MagicMirror? Please consider a donation!
                                            MagicMirror created by Michael Teeuw.
                                            Forum managed by Sam, technical setup by Karsten.
                                            This forum is using NodeBB as its core | Contributors
                                            Contact | Privacy Policy