Custom rules

Custom rules allow you to monitor the fleet behavior that is most important to your operations.

Custom rules can be created to monitor a wide variety of behaviors, depending on your needs. Some examples include:

  • Detecting fuel levels of vehicles

  • Detecting idling

  • Detecting when vehicles are making trips without an assigned driver

  • Detecting when a vehicle is being towed

A good custom rules usually contains two or three conditions. A rule with a single condition may trigger too many exceptions, while a rule with five or six conditions may never trigger any exceptions.

Creating rules based on vehicle type

Learn how to create rules that are customized to specific vehicle types, such as passenger vehicles or box trucks.

Before you can create rules based on vehicle types, you’ll need to create groups for each vehicle type you want to monitor, and assign the relevant vehicles to it.

Creating rules that are specific to certain vehicle types can produce more accurate exception data if you have a wide range of vehicle types in your fleet.

To create different rules based on vehicle type, we recommend creating groups for each weight class and customizing the ABC rules (hard acceleration, harsh braking, and harsh cornering) for each group.

  1. Navigate to Groups & Rules > Groups in the main menu.
  2. Locate the ABC rule (Hard acceleration, Harsh braking, or Harsh cornering) you want to customize under the Safety section and click the Pencil icon.
  3. Name your rule, and select a color as needed.
  4. Select the corresponding vehicle type group in the Publish to groups dropdown.
  5. Navigate to the Conditions tab.
  6. Select the Advanced conditions editor, indicated by the Page icon.
  7. In the editor box, edit the conditions to the sensitivity required by the vehicle class that corresponds to the rule.
  8. Click Save.
New custom rules can be found under the Advanced rules section.
Repeat the process for as many vehicle types as you have, customizing the conditions each time to correspond to the correct vehicle type.

Creating an idling rule for a set amount of time

Learn how to create a rule that alerts you when a vehicle has idled for a predetermined amount of time.

This rule uses a condition that uses duration between GPS logs to avoid the system recording the device as on and idling if it stops communicating.
  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Locate the Idling rule under the Sustainability section and click the Pencil icon. Select Edit conditions.
  3. Navigate to the Conditions tab.
  4. Select the Advanced conditions editor, indicated by the Page icon.
  5. In the editor box, edit time = to the time duration you want to trigger the rule.
  6. Click Save.
New custom rules can be found under the Advanced rules section.

Creating an idling rule for a particular zone

Learn how to create a rule that alerts you when a vehicle idles inside a predetermined zone.

Before you can create this custom rule, you'll need to create the zone or zone type where you want to track idling.
Adding a custom idling rule using this process does not alter or turn off the original idling rule. It creates a new custom rule that triggers independently of the original rule.
  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Locate the Idling rule under the Sustainability section and click the Pencil icon. Select Create custom idling rule.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Select Zone or zone type and specify whether the rule will be governed by specific zones or zone types.
  6. Select your desired zone or zone type in the Zone dropdown list.
  7. Set the Event that triggers the rule to Inside.
  8. Click Add to add the condition to your rule.
  9. Click Save.
New custom rules can be found under the Advanced rules section.

Creating an idling rule with a temperature condition

Learn how to create a rule that alerts you when a vehicle idles inside a predetermined temperature threshold.

Note: Adding temperature conditions to rules requires the Pro or Pro+ plan.
  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Locate the Idling rule under the Sustainability section and click the Pencil icon. Select Create custom idling rule.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Select Engine data and specify the type as Measurement or Data.
  6. In the Diagnostic field, type Outside air temperature and select the matching item from the dropdown list.
  7. Set the Value field to your desired temperature and specify if the rule should trigger when the detected air temperature is Over or Under the specified value.
    Note: At this time, MyGeotab only supports Celsius temperature measures.
  8. Click Add to add the condition to your rule.
  9. Click Save.
New custom rules can be found under the Advanced rules section.

Creating a fuel level rule

Learn how to create a rule that alerts you when a vehicle reaches a specified fuel level.

  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Click Add.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Select Engine data and specify the type as Measurement or Data.
  6. In the Diagnostic field, type Fuel level. You can select volume or percentage from the dropdown list, depending on how you want to measure the fuel level.
  7. Enter a fuel level value in the Value field, and specify whether the rule will be triggered when a vehicle is Over or Under this value.
  8. Click Add to add the condition to your rule.
  9. Click Save.
New custom rules can be found under the Advanced rules section.

Creating a rule to monitor unassigned vehicles

Learn how to create a rule to alert you if a vehicle is being driven without an assigned driver.

  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Click Add.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Select More > Driver from the available conditions.
    Note: If you cannot find the Driver condition in the conditions list, check that you have the necessary user permissions to view and change rule conditions related to drivers. Contact your Administrator to adjust your permissions if needed.
  6. Select Unknown driver in the Driver dropdown list.
  7. Click Add to add the condition to your rule.
  8. Add any other desired conditions, such as Ignition on and Driving.
  9. Click Save.
If your unassigned vehicle rule isn't producing exceptions when you expect it to:
  • Check the conditions you have set for the rule. Ensure that the Unknown Driver condition is selected.

  • Check that any additional conditions (such as Ignition ON or Driving) are accurately set up based on the type of activity you want to monitor.

  • Ensure the rule is enabled and applied to the vehicles or groups you want to monitor.

Creating a rule for IOX-Analog data

Learn how to create a rule to get data from the IOX-Analog device.

Creating a custom rule can allow you to get data from the IOX-Analog device and detail the frequency with which the device reports voltage data. Understanding this configuration and reporting behavior is crucial for effectively monitoring and using analog input data within MyGeotab.
  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Click Add.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Select the Advanced conditions editor (indicated by the Page icon).
  6. Paste the follow rule condition: IsValueMoreThan[value=10V](FilterStatusDataByDiagnostic[diagnostic=DiagnosticAnalogAux3Id]).
  7. Set the value in the condition to match the threshold relevant to your needs. For example, if you want to detect when a vehicle's heater is ON (assuming >10V indicates "ON"), set the value accordingly. Conversely, you could create a rule to detect when the heater is OFF (<10V).
  8. Select the appropriate Analog AUX input (1-4) connected to your equipment by navigating to the Add Engine tab and selecting Measurement or Data. Click Display All Diagnostics and then type Analog in the Diagnostic field and select the corresponding option in the dropdown menu.
  9. Click Add to add your condition to the rule.
  10. Click Save.
The voltage data reporting frequency for the IOX-Analog depends on the ignition status:
  • Ignition ON: The device reports data every 30 seconds or whenever a change in voltage is detected. This uses a curve logging algorithm to capture data efficiently. For more information on curve logging, please refer to How the curve algorithm for GPS logging works
  • Ignition OFF: The device reports data every time a change in voltage occurs. This triggers the device to wake up, send the voltage change data, and then return to sleep mode.

Creating a passenger occupancy rule

Learn how to create a rule that alerts you when a vehicle makes a trip with a passenger.

  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Click Add.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Select Engine data and specify the type as Measurement or Data.
  6. In the Diagnostic field, type Passenger occupancy and select Passenger occupancy (1 = occupied).
  7. Set the Value field to Over 0.
  8. Click Add to add the condition to your rule.
  9. Click Save.
New custom rules can be found under the Advanced rules section.

Creating a towing rule on the Base plan

Learn how to create a rule that alerts you when a vehicle is towed.

This custom rule is designed for customers using the Base plan.
  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Click Add.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Select the Advanced conditions editor, indicated by the Page icon.
  6. Paste the follow rule condition:
    And(
      IsValueMoreThan[value=10km/h](
        Speed
      ),
      And(
        IsValueMoreThan[distance=100m](
          TripDistance
        ),
        Ignition[false]
      )
    )
    
    Note: This condition checks if the vehicle’s speed is above 10 km/h and if the vehicle has traveled more than 100 meters while the ignition is off.
  7. Click Add to add the condition to your rule.
  8. Click Save.
New custom rules can be found under the Advanced rules section.

Creating a towing rule on the Pro or Pro+ plan

Learn how to create a rule that alerts you when a vehicle is towed.

This custom rule is designed for customers using the Pro or Pro+ plans.
  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Click Add.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Select the Advanced conditions editor, indicated by the Page icon.
  6. Paste the follow rule condition:
    And(
      IsValueMoreThan[value=0.020394324259558567G](
        FilterStatusDataByDiagnostic[diagnostic=DiagnosticAccelerationSideToSideId]
      ),
      And(
        IsValueLessThan[value=0.020394324259558567G](
          FilterStatusDataByDiagnostic[diagnostic=DiagnosticAccelerationForwardBrakingId]
        ),
        Or(
          IsValueMoreThan[value=4km/h](
            Speed
          ),
          IsValueMoreThan[value=0.020394324259558567G](
            FilterStatusDataByDiagnostic[diagnostic=DiagnosticAccelerationForwardBrakingId]
          )
        )
      ),
      Ignition[false]
    )
    
    
    Note: This condition checks for significant side-to-side acceleration (indicating movement without power) while forward/braking acceleration is low, the speed is above 4 km/h, and the ignition is off.
  7. Click Add to add the condition to your rule.
  8. Click Save.
New custom rules can be found under the Advanced rules section.

Creating a custom speeding rule using the default speeding rule

Learn how to create a rule to alert you if a vehicle is speeding based on the default built-in speeding rule.

  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Locate the Speeding rule under the Safety section and click the Pencil icon.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Select the Advanced conditions editor, indicated by the Page icon.
  6. In the editor box, edit the time= to the time duration you want to trigger the idling rule.
  7. Click Save.
New custom rules can be found under the Advanced rules section.

Creating a custom speeding rule manually

Learn how to manually create a rule to alert you if a vehicle is speeding.

  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Click Add.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Click Speed and enter a value in the Speed field. Select whether the rule will trigger when the vehicle is Over or Under this speed.
  6. Click Add to add the condition to your rule.
  7. To limit your rule to speeding within a particular zone, select Zone or Zone type and select a zone or zone type from the Zone dropdown list. Select Inside as the event that will trigger the event. Click Add to add the condition to your rule.
  8. Click Save.
New custom rules can be found under the Advanced rules section.

Creating a custom speeding rule based on percentage

Learn how to create a rule to alert you if a vehicle is speeding by a predetermined percentage over the speed limit.

  1. Select Groups & Rules > Rules in the main menu.
  2. Click Add.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Click Speed limit.
  6. Select Percentage in the dropdown list for the Over the limit by field, and specify your percentage.
  7. Click Add to add the condition to your rule.
  8. Click Save.
New custom rules can be found under the Advanced rules section.

Creating a custom speeding rule based on different posted speed limits

Learn how to create a rule to alert you if a vehicle is speeding that is based on two different speed thresholds.

  1. Navigate to Groups & Rules > Rules in the main menu.
  2. Click Add.
  3. Name your rule, and select a color or groups as needed. Leaving the Publish to groups field empty will publish the rule to the Company group by default.
  4. Navigate to the Conditions tab.
  5. Click Roads with speed limit. Select Over and specify a speed in the Roads with speed limit field.
  6. Click Add to add the condition to your rule.
  7. Click Roads with speed limit again. Select Under and specify a second speed in the Roads with speed limit.
  8. Click Add to add the condition to your rule.
  9. Click Speed limit. Specify a third speed in the Over the limit by.
  10. Click Add to add the condition to your rule.
  11. Click Save.
New custom rules can be found under the Advanced rules section.