Smart Bike Lights (Data Field) / Bike Lights Control (Widget)

I've made two open source CIQ applications to control ANT+ lights:

- Smart Bike Lights (data field): https://apps.garmin.com/en-US/apps/0d9fd828-c932-4470-9c37-fd2828881888 

      Configurator: https://maca88.github.io/SmartBikeLights/ 

- Bike Lights Control (widget): https://apps.garmin.com/en-US/apps/fa3c2332-76e3-4ba1-8528-32a0fd617ab1 

     Configurator: https://maca88.github.io/BikeLightsControl/ 

Smart Bike Lights features:
- Automatic light control (Smart mode) based on the configured filters (sunset, sunlight, speed, ...)
- Manual light control (only for Edge devices with a touch screen or devices with CIQ 3.2 and more than 32KB memory)
- Records lights modes that are displayed in Garmin Connect

Bike Lights Control features:
- Manual light control (available to all devices)

Both applications can be installed on the same device, which can be useful for low end devices (e.g. Edge 520) where "Bike Lights Control" can be used to change light modes manually and "Smart Bike Lights" for automatic light control.

Currently registered ANT+ lights:
- Bontrager Ion Pro RT
- Bontrager Ion 200 RT
- Bontrager Flare RT
- Garmin Varia RTL500
- Garmin Varia RTL510
- Garmin Varia RTL515
- Garmin Varia HL500
- Garmin Varia UT800

in case your ANT+ light is not on the list you can help by doing the following:

1. Install Bike Lights Control
2. Pair your bike light with your Garmin device
3. Open the widget:
- Edge with a touch screen: post which numbers are displayed on the buttons and what mode each button represents when pressed
- Other devices: Select the "Light modes" menu and post which numbers are displayed in the menu and what mode each menu item represents when selected

Example for Bontrager Ion Pro RT:


1 -> High steady beam
2 -> Medium steady beam
5 -> Low steady beam
63 -> Day flash
62 -> Night flash

There are some features that could be possible to add in the future, but would require Garmin to add them to the CIQ api. In case you are interested in any of the below features, consider upvoting their feature request thread:

1. Control lights based on the ambient light sensor available on some devices:
https://forums.garmin.com/developer/connect-iq/i/bug-reports/ambient-light-sensor-api-access 

  • created a 1 data field data screen. loaded some basic configuration (via ConnectIQ iOS app) and it seemed to work well.
    a day later, the data screen just shows "error 1"
    Any idea what to do?

  • @4049204

    Maybe - that's at least the preliminary conclusion I've arrived at - that behavior happens when there's more than one "app" trying to control those lights?

    I ran for quite a long time - without being aware of it - the Garmin light control widget while I also had the Bontrager Light Control data field installed. After uninstalling the Bontrager data field months ago the lights - I've got two Ion Pro RT and two Flare RT - were always found by my Edge 1030.

    The only thing that led me to investigate if there isn't a better solution - and that's how I found maca88's work - is that I could not control the intensity of the constant beam of the headlight through the Garmin widget. And running those on high beam drains the battery quickly.

    So now I've maca88's Bike Lights Control installed and configured and the Garmin Light Control widget deactivated. Things look good so far.

  •   @4049204, remember sensor ids from Garmin menu -> delete all lights from sensors -> reset lights -> make config with individual network for smart light data field. All works like a charm

  • I know, been there. But still only one light connects or sometimes zero. It's slightly better than with the original app tho. Also it switches to Manual mode all of the time. I know, there are also options for that.

  • Thank you for doing this app. it is solving a real need.
    As a new user, I need some help with the configurator: I have Edge 1040, Bontrager ION pro RT as headlight and Flare RT as taillight.
    I would like the lights to start as soon as I start moving (even before starting the recording of an activity) and turn off as soon as I save the activity at the end of my ride.
    Is there a way to do it? can you share a configuration?
    Will I be able to load the configuration string to the configurator to do additional tweaks? I want to make the light behave differently for day/night etc.

  • It's frustrating. Also after each charge, they get deeply disconnected and battery status wrong, so a very big ceremony is needed every time.

    I feel you, I had the same issues with my Flare RT. I "solved" the issue by switching to Garmin Varia and the connection issues for me disappeared without using the "Individual Light Network" feature. For some reason, when using the native way of connecting the lights, Flare RT was always picked as the main light and I believe that is the root cause for the connection issues. For context, when pairing the lights within the Garmin Sensors menu, one light is promoted to be the "main light". The main light is the only light connected to Edge, other lights are only connected to the main light. So, every command goes through the main light, then the main light forwards the command to other (secondary) lights when necessary.

  • a day later, the data screen just shows "error 1"

    If you have Edge 1040, this can unfortunately happen when Edge is waken up from sleep. The only reliable way to solve the problem (at least on my 1040), is to turn off Edge and then turn it back on. If that works also for you, I would recommend you to turn Edge off instead of putting it to sleep when you take a break during an activity.

    Is there a way to do it? can you share a configuration?

    Yes, here is the configuration:

    1,1!:1C]0#4587520,196641::1#3,3!DAY:1:63:0:0Er0,s0!NIGHT:1:62:0:0Es0,r0!:1:63:0:0D=1#6291461,1409482753::1#3,3!DAY:1:7:0:0Er0,s0!NIGHT:1:63:0:0Es0,r0!:1:7:0:0D=1#7,6:Ion Pro RT:0:16777215!2,:-1,Off:0!1,High:1!1,Medium:2!1,Low:5!1,Day Flash:63!1,Night Flash:62#7,6:Flare RT:0:16777215!2,:-1,Off:0!1,Day Steady:1!1,Night Steady:5!1,Day Flash:7!1,All-Day Flash:8!1,Night Flash:63#0::#0:0#123!:123!#0#0#B3843#1#1#0#0


    The lights will turn on only when you are moving (speed > 0) and by default "Day Flash" mode will be used. When the GPS location is acquired then the "Sunset/Sunrise" filter will kick in and both lights will go to "Day Flash" at daytime and "Night Flash" during night time.

    Will I be able to load the configuration string to the configurator to do additional tweaks?

    Yes, you will. Copy the above configuration, paste it in the "Existing configuration" input field of the Lights Configurator and press the "Load" button to load the configuration.

  • TREK CarBack & Garmin Edge 1040

      1 ->  Day steady
      5 ->  Night steady
      8 ->. Day flash
    63 -> Night flash

  • ###::16711680###6,5:CarBack:5614335:16777215!2,:-1,Off:0!1,Day steady:1!1,Night steady:5!1,Day Flash:8!1,Night Flash:63#0::#0:0#B3843##99#0#0

  • Thanks for the light modes! Now you can select the light in the Lights Configurator, without having to use the "Unknown" light