• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
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.

Fitbit

Scheduled Pinned Locked Moved Troubleshooting
129 Posts 42 Posters 179.5k Views 37 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.
  • B Offline
    bhepler Module Developer @Achilles
    last edited by Aug 18, 2018, 1:58 PM

    @achilles - That happened to me about three weeks ago. I had to get back on the mirror and run the setupAccess.py script to authorize with fitbit.com again. After that it started working again. You’ll probably find an indication of what’s up in the pm2 logs.

    Fitbit is weird in that they insist that you use their website to authenticate. You can’t get an API key for you app. Your app must incorporate a means to go to their website to use their interface and then return.

    1 Reply Last reply Reply Quote 0
    • A Offline
      Achilles
      last edited by Aug 19, 2018, 12:09 AM

      @bhepler - At the risk of sounding stupid, you have to go back and run through the commands again and get to setupAcess.py to get Fitbit to work again?

      B 1 Reply Last reply Aug 20, 2018, 5:23 PM Reply Quote 0
      • B Offline
        bhepler Module Developer @Achilles
        last edited by bhepler Aug 20, 2018, 5:23 PM Aug 20, 2018, 5:23 PM

        @achilles - Almost. You just have to run the setupAccess.py again. So get onto your Pi directly, open up a terminal window, stop your MagicMirror process, and run the sudo python setupAccess.py or whatever the command is. It will open up a browser window with the FitBit login page. Log in with your credentials, wait for the confirmation screen and then close the browser.

        Restart your MagicMirror process and it should start pulling from the FitBit service.

        1 Reply Last reply Reply Quote 0
        • A Offline
          Achilles
          last edited by Aug 23, 2018, 9:14 PM

          @bhepler Thanks! That helped. I guess this means I can look forward to doing this every month or so?

          B 1 Reply Last reply Aug 24, 2018, 12:50 PM Reply Quote 0
          • B Offline
            bhepler Module Developer @Achilles
            last edited by Aug 24, 2018, 12:50 PM

            @achilles - I don’t actually know. Mine was up for months with no issue. It may be that a prolonged period without the module refreshing the tokens is the determining factor. It may even be something on Fitbit’s end expired all of the tokens.

            1 Reply Last reply Reply Quote 0
            • M Offline
              mmille40
              last edited by Sep 10, 2018, 1:15 AM

              This module looks great, unfortunately the installation is giving me the most difficulties from any module so far, I’m completely new to anything coding so I’m learning as I go. My first problem was trying to install the python-shell dependency. I get this message in my terminal:

              pi@matt:~ $ npm install python-shell
              npm WARN saveError ENOENT: no such file or directory, open ‘/home/pi/package.json’
              npm WARN enoent ENOENT: no such file or directory, open ‘/home/pi/package.json’
              npm WARN pi No description
              npm WARN pi No repository field.
              npm WARN pi No README data
              npm WARN pi No license field.

              • python-shell@1.0.4
                updated 1 package in 2.932s

              What am I doing wrong here?

              1 Reply Last reply Reply Quote 0
              • D Offline
                dh1201
                last edited by Oct 2, 2018, 3:04 PM

                See issue from mmille40 (above).

                I am running ‘npm install python-shell’ from within the MagicMirror/modules/MMM-fitbit folder and appear to be having the exact same issue [although the location of the file that cannot be found is reported differently to mmille40’s location] and am unable to discover the reason why. Does anyone have any ideas?

                npm WARN saveError ENOENT: no such file or directory, open ‘/home/pi/MagicMirror/modules/package.json’
                npm WARN enoent ENOENT: no such file or directory, open ‘/home/pi/MagicMirror/modules/package.json’
                npm WARN modules No description
                npm WARN modules No repository field.
                npm WARN modules No README data
                npm WARN modules No license field.

                • python-shell@1.0.4
                  updated 1 package and audited 2 packages in 3.126s
                  found 0 vulnerabilities
                S 1 Reply Last reply Oct 2, 2018, 5:18 PM Reply Quote 0
                • S Offline
                  sdetweil @dh1201
                  last edited by Oct 2, 2018, 5:18 PM

                  @dh1201 this says u are in the MODULES folder, not MMM-Fitbit

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  1 Reply Last reply Reply Quote 0
                  • D Offline
                    dh1201
                    last edited by Oct 2, 2018, 6:23 PM

                    Should it be the modules directory then?

                    Set up states:

                    As with all modules, use git clone in the modules directory to download the module
                    Goto fitbit to register a new app (sign in with your fitbit account)
                    Give your app a catchy name and description
                    Your personal website, organisation, and organisation website can be whatever you like
                    Check browser and personal for OAuth settings
                    Callback URL MUST BE http://127.0.0.1:8080/
                    Give your app read & write permissions (read-only untested)
                    Note your:
                    “OAuth 2.0 Client ID” — (client_id)
                    “Client (Consumer) Secret” — (client_secret)
                    (You can access these again later via manage my apps at the same link as above)
                    Navigate to MMM-fitbit in the modules directory
                    Install dependancies using the listed commands

                    1 Reply Last reply Reply Quote 0
                    • D Offline
                      dh1201
                      last edited by Oct 2, 2018, 6:43 PM

                      Sorry @sdetweil - I misread your post.

                      The command is definitely being run from within the MMM-fitbit directory; but shows the errors previously posted.

                      1 Reply Last reply Reply Quote 0
                      • 1
                      • 2
                      • 9
                      • 10
                      • 11
                      • 12
                      • 13
                      • 11 / 13
                      • 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