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 

  • Now I noticed weird behaviour: recently I bought Varia 515, and when varia detect car it switch light mode - and this mode stays (the same with Di2 Fly buttons), I need to switch to Smart Bike Lights data screen - then it switch back to my automations :(. Why background stop working? TyreWiz causing this issue?

  • Yes, usually the numbers are fixed for a specific light model by the light manufacturer. I never seen a light where the mode numbers change based on the settings.

    I tested now: YES it change numbers. I have model Magene AT 1600.
    And it have by default these modes: 1,2,3,4,5,6,7 AND some custom modes 59,60,61,62,63 (which at first are empty - do not nothing if you press). I was able to create custom mode - and it assign to 59, next created custom mode and it assigned to 60. For example: then was missing 59 in the list at first - only when I create first custom mode - only then it show 59 (seems it is able to create these numbers on the fly). But, when I delete these custom modes and create them again, not always it assign to these custom number (which starts from 59...), not sure why, and how it decide to which number assign, need more tests... or maybe I will try contact Magene support

  • And other issue: with multiple lights - if I have Varia 515 & Flare RT - all works, just until one light is Off (battery dead or turn off), because configuration requires to select specific Taillight - and if this one will be off, then you will not be able to control other light even you have still running other taillight. For example: Varia 515 - I like to disable when I ride on separate bicycle lane, because it captures a lot noice from near heavy road. But if I configure by default Flare RT, and it will be off (battery dead), then I will loose control of the Varia 515 - problem :).
    Maybe it would be possible to have "pages" - like with lap "summary" page, where we can have multiple lights if they are connected. Now it's limited to two columns - and it create dependency on single light (even you combine them)

    The same will be with Headlight: if I have Magene AT1600 as main light, and I have UT800 for example as Helmet Light. I don't want to have dependencies - if one of them are off (by battery, or other reason), I still want to control it. Also if you group them - I loose light modes, which is not perfect.

    My suggestions:
    1. Group by Lights - 1,2,3, etc. allow to add multiple lights into one group - and this group will have it's own automations. And allow to create these multiple groups (Headlights, Taillights, or any other logical group).

    2. Pages - allow to have multiple pages if you have more than two lights. Also would be nice to allow reorder - which light on which page, and on which side of the screen

    Then I will have all light modes for all my multiple lights, and also if one of these lights off (for any reason), I still will be in control with others (there is no dependency)

  • Thanks. I ended up creating the configuration manually, but here's the mapping. Low and high flash are hard to tell apart, but I think it's right.

    4 - High Steady

    5 - Low Steady

    6 - Low Flash

    7 - High Flash

  • Hi maca,

    Today I had time to test Magene AT1600.
    You have map for AT1200, all ID's are the same, just except 63 - it's not light mode (do nothing), instead it is 61.
    Please create this map for AT1600:
    const mageneAt1600Modes = [
    { id: 0, name: 'Off' },
    { id: 1, name: 'Very High' },
    { id: 2, name: 'High' },
    { id: 3, name: 'Medium' },
    { id: 4, name: 'Medium-Low' },
    { id: 5, name: 'Low' },
    { id: 6, name: 'Slow Flash' },
    { id: 7, name: 'Strobe' },
    { id: 61, name: 'Fast Strobe' }];

    Also after a lot testing I found that I can assign custom modes to Ant+ ID's - BUT just only two available (in my case it's enough)

    62 & 63 - empty ID's, and can't assign any light mode (not sure what are these).

    59 & 60 - I can assign custom light modes on these ID's!!!
    How to do that:
    AT1600 allow to have max 10 Presets (light modes: custom or predefined) - and only last 2 presets will get ANT+ ID's:

    • 9 preset will get 59
    • 10 preset will get 60

    P.S> I also send email to Magene support, ask about possibility to define ANT+ ID dynamically - via they app.

  • I just test: When I remove TyreWiz app - your app start working, I don't need to switch data screens so it would update status & automations.
    That's a bummer..., I want to see tyre pressure, that's the whole point why I bought TyreWiz 2.0 Slight smile
    Maybe you can check with developer:
    https://apps.garmin.com/apps/d1d7fe09-0f41-4067-94f4-2f8512a14737?tid=2
    P.S> I reported this problem to him, and also asked him to check with you Slight smile

  • With multiple lights I have other issue:
    Headlight Magene AT1600, Taillight Trek Flare RT, and Varia 515.
    When you combine (Garmin feature?) taillight - I loose a lot of light modes.
    As temp workaround I though I will use Smart Bike Lights #2 data field only for Varia 515, and Smart Bike Lights #1 data page for Magene AT1600 & Trek Flare RT.
    BUT... problem is that it show error or no network on #1 (even I try to enter lights serial numbers), I know that network exist, because I see in Garmin widget and see sensors connected. When it's combined - maybe you can't split???

  • S/N I was using wrong number :(, now seems work (I can split Flare RT & Varia 515 with S/N).

    But, I  found other issue/bug:
    Magene AT1600 - I can't select 'Unknown', and change 63 to 61 (which is correct for me), because then Magene is not recognised (even I see it on #2 page, where I don't have any config), if I set to MageneAT1200/1600 then all works (even with S/N).
    So, I now I'm stuck with 63 for Magene AT1600 - which is empty. Also it will block me using custom modes :((( something is weird that if I select Unknown, and then define light modes - it is not working, if I select model - it start working (with or without S/N) 

  • "Record lights mode" - what it do?, I can't find explanation Slight smile

  • > I tested now: YES it change numbers.

    Good to know, thanks for the info.

    > Please create this map for AT1600:

    Done, now there is a separate option for AT1600 in the Lights Configurator.

    > if I have Varia 515 & Flare RT - all works, just until one light is Off (battery dead or turn off), because configuration requires to select specific Taillight

    there are currently two ways on how to control multiple lights of the same type (e.g. Varia 515 & Flare RT) which is documented here: https://github.com/maca88/SmartBikeLights?tab=readme-ov-file#control-multiple-lights-of-the-same-type 

    In short, if you do not want do have dependencies, then you will need to install Smart Bike Lights #2 then setup Varia 515 + UT800 with "Smart Bike Lights" and Magene AT1600 Flare RT with "Smart Bike Lights #2" data field. If you paired the lights with the native approach (not using individual network from Smart Bike Lights), then you will need to set the serial number for each light as you aready did.

    > When you combine (Garmin feature?) taillight - I loose a lot of light modes.

    this is a Smart Bike Lights feature which will automatically groups lights of the same type, when serial number is not set. When combining Flare RT and Varia 515 only two modes can be shared (5 and 7). Check the documentation above, which describes this exact scenario.

    > something is weird that if I select Unknown, and then define light modes - it is not working, if I select model - it start working (with or without S/N)

    What do you mean is is not working, do you get an error X or No network? If yes, please provide the both the unknown config that does not work and the one that does work. I would like to see what could be the issue. In theory, you should be able to use Unknown to configure any light. The only thing that will not work with Unknown are the light icons, where you will always see "?" for each light mode.

    > "Record lights mode" - what it do?, I can't find explanation

    It is briefly described here: https://github.com/maca88/SmartBikeLights?tab=readme-ov-file#settings
    When enabled, it will record the light modes during an activity and you will be able to see the light modes in Garmin Connect as a graph. The only thing to note is that the light modes are recorded as numbers (1, 5, 61, 63, ...), as this is the only way to create a graph in Garmin Connect.

    > That's a bummer..., I want to see tyre pressure, that's the whole point why I bought TyreWiz 2.0 Slight smile Maybe you can check with developer:

    The only way to make TyreWiz 2.0 work with Smart Bike Lights is to update "TyreWiz Data Field" to avoid using background services. I am not really sure why a background service is required to retrieve data from Quarq TyreWiz. Maybe, the developer of "TyreWiz Data Field" could make the background service optional or remove it entirely if it is not needed. For Tempe sensor, I created a new data field which does not use a background service, so it should be possible to the the same also for Quarq TyreWiz, unless I am missing something.