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.

    NSW Fuel Prices

    Scheduled Pinned Locked Moved Unsolved Requests
    21 Posts 3 Posters 11.4k Views 3 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.
    • strawberry 3.141S Offline
      strawberry 3.141 Project Sponsor Module Developer @k3tan
      last edited by strawberry 3.141

      @k3tan https://github.com/fewieden/MMM-Fuel/blob/626b1434e64380475f6430086ce47bebb038b8ed/README.md#nsw-australia-nsw-only

      {
        module: "MMM-Fuel",
        position: "top_right",
        config: {
          provider: 'nsw',
          api_key: 'YOUR_API_KEY',
          secret: 'YOUR_API_SECRET',
          lat: -33.881964,
          lng: 151.172128,
          types: ["diesel", "e5"],
          sortBy: "diesel",
          radius: 10,
          max: 5,
        }
      },
      

      Please create a github issue if you need help, so I can keep track

      K 2 Replies Last reply Reply Quote 0
      • K Offline
        k3tan @strawberry 3.141
        last edited by

        @strawberry-3-141
        thanks. i’ve just done some testing.

        couple of comments so far:

        • your ‘E5’ is picking up P95. Can you change the heading to P95?
        • your diesel (DL) price is correct for stations that have diesel. however, if the station has premium diesel (PDL), it shows as “>155.9”.

        The possible fuel types the API serves are the following:
        Ethanol 94 (E10)
        Unleaded 91 (U91)
        Ethanol 105 (E85)
        Premium 95 (P95)
        Premium 98 (P98)
        Diesel (DL)
        Premium Diesel (PDL)
        Biodiesel 20 (B20)
        LPG (LPG)
        CNG/NGV (CNG)
        EV charge (EV)

        Are all these fuel types supported, or just E5 and Diesel at this stage? If I change the fuel type to E10 for instance, would it work?

        Also, I have a list of favorite stations I want to keep tabs on. Is it possible to feed those specific stations in and get the price of those?

        thanks for all your help so far, much appreciated!

        1 Reply Last reply Reply Quote 0
        • K Offline
          k3tan @strawberry 3.141
          last edited by

          @strawberry-3-141 hey mate, just went through some of your code as well as the API itself. i see there’s a page for ‘closest stations’ and a ‘cheapest stations’. is it possible to get like a page of ‘favorites’ where i can input stationcode and display those?
          i don’t really need cheapest and closest.
          ps. ive also figured out that only P95 and Diesel work at this stage. all good.
          cheers

          strawberry 3.141S 1 Reply Last reply Reply Quote 0
          • strawberry 3.141S Offline
            strawberry 3.141 Project Sponsor Module Developer @k3tan
            last edited by

            @k3tan you’re right e5 => P95 and diesel => DL as their are known here.

            If a station is not providing one of the fuel types the module takes the most expensive price for that type that it got as a response and puts a greater than before.

            Favourites are not implemented and also not trivial to do, as all data providers are based on nearby searches and limited in the response.

            Please create a github issue if you need help, so I can keep track

            1 Reply Last reply Reply Quote 0
            • P Offline
              Peter Leemon @strawberry 3.141
              last edited by

              @strawberry-3-141 can this be used for other states as well (Qld)?

              1 Reply Last reply Reply Quote 0
              • 1
              • 2
              • 3
              • 3 / 3
              • 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