How to set up HDS Grind by Weight

HDS Grind by weight lets your Half Decent Scale (HDS) automatically control a grinder through a compatible Tasmota smart plug (picture on the right).

Once everything is set up, the scale can turn the grinder plug on, monitor the weight of the coffee being ground, switch the grinder off near your target dose, and prepare itself for the next dose.

This guide walks through the setup in simple steps.

Tasmota plug

What you need

Before starting, make sure you have:

  • An HDS scale with firmware that includes the Grind by weight plugin
  • A compatible Tasmota smart plug
  • The Grind by weight plug firmware installed on that smart plug
  • The scale and smart plug connected to the same Wi-Fi network
  • Your grinder plugged into the smart plug
  • A dosing cup

  • The required smart-plug firmware is available from Decent Espresso's tasmota-auto-doser project.

    Step 1: Set up the smart plug

    Install the required firmware on your Tasmota smart plug.

    Then connect the plug to the same Wi-Fi network that your HDS scale will use.

    For now, keep your grinder's physical power switch OFF. You will test the system safely before allowing the grinder motor to run.


    Step 2: Enable Grind by weight on the scale

    On your HDS scale:

    1. Install or flash firmware that includes the Grind by weight plugin. You can find this on the HDS Custom Build website. We explain how to use that website here.
    2. Connect the scale to Wi-Fi.
    3. Open the HDS Setup menu.
    4. Select Grind by weight.
    5. Select Enable.
    6. Select Select Plug.
    7. Choose your smart plug from the list.
    8. Adjust the grinder settings if needed.
    9. Select Back to leave the menu.

    The scale identifies the plug using its MAC address. Its hostname and IP address are only stored to help find it faster later.


    Step 3: Do the first test with the grinder switched off

    Do not turn on the grinder's physical switch yet.

    This first test confirms that the scale and smart plug are communicating correctly without actually starting the grinder.

    After leaving the menu, the scale should eventually display:

    Tare to arm

    Now:

    1. Put your empty dosing cup on the scale.
    2. Press tare.
    3. Leave the cup still.
    4. Wait for the display to show Ready.
    5. Confirm that the smart plug relay switches on.
    6. Slowly add weight to the cup or scale.
    7. Continue until the cutoff point is reached.
    8. Confirm that the smart plug switches off.
    9. Remove the added weight.
    10. Return the empty cup to the scale.
    11. Wait for the display to return to Ready.

    Only turn on the grinder's physical switch after this test works reliably.


    Step 4: Choose your target dose

    The default settings are:

  • Target: 15.0 g
  • Safety: 2.0 g
  • Zero range: -1.0 g to 1.0 g
  • Zero hold: 1000 ms
  • Target tolerance: 0.5 g

  • The most important setting for normal use is Target g.

    For example, if you normally want to grind 18 grams of coffee, set:

    Target g = 18.0

    When Grind by weight is enabled, you can open its menu from the normal weight screen by holding both buttons for about 500 ms.


    Step 5: Understand the Safety setting

    The grinder does not normally switch off exactly at the target weight.

    Instead, the cutoff is calculated as:

    Target weight − Safety weight

    For example:

    15.0 g target − 2.0 g safety = 13.0 g cutoff

    This means the grinder is told to stop at about 13 g.

    Why so early?

    Because coffee grounds can continue falling into the cup for a short time after power is removed from the grinder. The earlier cutoff helps the finished dose land closer to the actual target.

    You generally do not need to constantly adjust this yourself. The system can learn a better safety value from normal completed doses.


    Step 6: Make your first real dose

    Once the dry test is working correctly, turn on the grinder's physical switch.

    For the first grind:

    1. Put the empty dosing cup on the scale.
    2. If the display says Tare to arm, press tare.
    3. Leave the cup still.
    4. Wait for Ready.
    5. The smart plug should now be supplying power.
    6. Start the grinder physically if your grinder requires it.
    7. Coffee begins falling into the cup.
    8. The display changes to Grinding after the scale detects a plausible rising dose.
    9. When the cutoff point is reached, the scale sends the OFF command.
    10. Wait for the dose to finish falling.
    11. Remove the filled cup.

    That completes one Grind by weight cycle.

    Important — grinders with a latching physical switch:

    A latching switch can stay in the ON position even after the smart plug cuts power. Move the grinder's physical switch back to OFF before returning the empty cup to the scale. Otherwise, when Grind by weight rearms and the smart plug turns on again, the grinder can start immediately.


    Step 7: Prepare for the next dose

    You do not normally need to press tare after every grind.

    After removing the full dosing cup:

    1. If your grinder has a latching physical switch, move it back to OFF first.
    2. Empty the cup.
    3. Put the empty cup back on the scale.
    4. Leave it still.
    5. Wait for the weight to settle around zero.
    6. The scale will automatically return to Ready.

    With the default settings, the cup needs to remain stable around zero for about one second before the system rearms.

    Remember: when the system rearms, the smart plug can supply power again. If a latching grinder switch has been left ON, the grinder may start as soon as the plug rearms.


    What the display messages mean

    Here are the most useful messages to know.

    WiFi wait

    The scale is waiting for Wi-Fi.

    Check that the scale can connect to its saved network.

    Plug wait

    The scale cannot currently reach the selected smart plug.

    Check that the plug is powered and connected to the same network.

    Tare to arm

    The scale has found the plug, but the grinder is being kept safely off.

    Put the empty dosing cup on the scale and press tare.

    Zero wait

    The scale is waiting for a stable zero reading.

    Leave the empty cup alone until the reading settles.

    Ready

    Everything is armed and ready to grind.

    The plug relay is ON.

    If your grinder uses a latching physical switch, remember that leaving that switch ON can make the grinder start as soon as the system reaches this state.

    Grinding

    The scale has detected a normal-looking increase in coffee weight.

    Let the grind continue.

    Stopping

    The scale has sent the OFF command and is waiting for confirmation.

    Remove cup

    The dose has finished.

    Remove the filled dosing cup.

    Await zero

    The scale is waiting for the empty cup to return.

    Before returning it, make sure a latching grinder switch has been moved back to OFF.

    Then put the empty cup back and leave it still.

    Busy

    Another scale or client is already using the smart plug.

    Disconnect the other client or restart the plug.

    Error

    Grind by weight has entered its fail-safe state.

    Check the smart plug and reconnect Grind by weight.


    How automatic learning works

    Grind by weight can adjust its Safety value automatically.

    Suppose your target is:

    15.0 g

    but your finished dose repeatedly ends at:

    15.3 g

    The system can increase the safety value for future doses so that it switches the grinder off slightly earlier.

    It uses the most recent three valid recommendations when calculating the adaptive value.

    It will avoid learning from unusual doses, such as when:

  • The final weight never becomes stable
  • The cup is removed too early
  • Weight falls after the grinder switches off
  • Grinding stops before reaching the target
  • The measured grind rate is unusually high
  • The final result is too far from the target

  • This helps prevent a mistake or unusual grind from affecting future doses.


    If the scale will not rearm

    After a dose, Grind by weight needs three things before it becomes ready again:

    1. The filled cup must be removed.
    2. The empty cup must be returned.
    3. The cup must remain stable inside the zero range.

    The default zero-hold time is 1000 ms, or one second.

    If the scale still will not rearm, make sure the empty cup is actually close to zero and is sitting completely still.

    Before trying to rearm, also make sure a grinder with a latching physical switch has been switched back to OFF.


    If the scale says Plug wait

    The selected plug cannot currently be reached.

    Check:

  • The smart plug is powered
  • The plug and scale are on the same Wi-Fi network
  • The plug service is running
  • The saved hostname still works
  • The saved IP address still belongs to the correct plug

  • If the plug's IP address has changed and the scale cannot find it again automatically, open the menu and run Select Plug again.


    If the scale says Tare to arm

    This is normally a safety feature, not a fault.

    The plug connection is working, but the grinder will remain off until you perform a deliberate tare.

    Place the empty dosing cup on the scale and press tare.

    Automatic startup or recovery tares do not arm the grinder.


    Important safety points

    A few rules are worth remembering.

    Always perform the first test with the grinder's physical switch off.

    The scale controls power to the smart plug. It does not operate the grinder's physical switch.

    >If your grinder has a latching physical switch, always return that switch to OFF after the plug stops the grinder and before returning the empty cup.

    Cutting power at the smart plug does not change the position of a physical latching switch. If that switch remains ON, the grinder can start immediately when the empty cup is returned, the system rearms, and power is restored.

    Also, once the display says Ready, the scale only knows that weight is being added. It cannot tell whether that weight is coffee or another object.

    If you change the cup, move the setup, or place something different on the scale, tare again before grinding.

    The system is also designed so that losing the active plug connection causes the plug to switch off rather than continue running.


    Everyday workflow

    Once everything is configured, normal operation is simple:

    1. Put down the empty cup.

    2. Tare if the scale asks you to.

    3. Wait for Ready.

    4. Start the grinder.

    5. Let the scale cut power at the target.

    6. Remove the filled cup.

    7. If the grinder has a latching switch, move it back to OFF.

    8. Empty and return the cup.

    9. Wait for Ready.

    10. Repeat.

    The key safety habit is simple:

    Grinder stops → physical switch OFF → empty cup returns.

    After the initial setup, most of the networking, cutoff calculation, adaptive safety, and rearming happens automatically in the background.

    #HDS #HalfDecentScale #scale #features #grindbyweight #documentation




    mirjam created 2026/09/10.