# Missing LED mappings in metal.h

**URL:** <https://forums.sifive.com/t/missing-led-mappings-in-metal-h/2336>\
**Category:** HiFive1 Rev B\
**Created:** [May 16, 2019, 3:38pm UTC](https://forums.sifive.com/t/missing-led-mappings-in-metal-h/2336 "2019-05-16T15:38:33Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Almindor](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/almindor/32/662_2.png) [@Almindor](https://forums.sifive.com/u/Almindor)\
**Post date:** [May 16, 2019, 3:38pm UTC](https://forums.sifive.com/t/missing-led-mappings-in-metal-h/2336/1 "2019-05-16T15:38:33Z")

</div>

It seems current version of metal.h for the hifive 1 rev B board is missing LED definition?

In metal.h:

```auto
#define __METAL_DT_MAX_LEDS 0

asm (".weak __metal_led_table");
struct __metal_driver_sifive_gpio_led *__ metal_led_table[] = {
					NULL };

```

which leads calls to `metal_led_get_rgb` to return `NULL`

It seems this is the case for all the board types with the current freedom-sdk. Is there any way to find the LED table mappings? Any docs for this?

---

<div class="post-metadata">

**Author:** ![bruce](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/bruce/32/452_2.png) [@bruce](https://forums.sifive.com/u/bruce)\
**Post date:** [May 16, 2019, 3:49pm UTC](https://forums.sifive.com/t/missing-led-mappings-in-metal-h/2336/2 "2019-05-16T15:49:01Z")

</div>

This is implemented in the 19.05 branch, which will be released soon.

---

<div class="post-metadata">

**Author:** ![thornschuh](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/thornschuh/32/134_2.png) [@thornschuh](https://forums.sifive.com/u/thornschuh)\
**Post date:** [May 16, 2019, 7:54pm UTC](https://forums.sifive.com/t/missing-led-mappings-in-metal-h/2336/3 "2019-05-16T19:54:02Z")

</div>

I actually run in the same problem.  
I just checked out the development-19.05 branch, so no need to wait for release 🙂  
Dont forget to run a submodule afterwards. So the complete command is:

```
git fetch
git checkout development-19.05
git submodule update --init --recursive

```

Some other remark: Different from the Getting started guide and the older version of the HiFive board the welcome program does not emmit the “Are the LEDs changing” message anymore. It just emmits the logo and “Welcome to SifFive” and then the LED is flashing in nice colors.

BTW: The SDK examples can only be compiled with the SiFive version of RISC-V gcc, because of CLIC csr registers. In addtion also gdb must be from SiFive build

---

<div class="post-metadata">

**Author:** ![Almindor](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/almindor/32/662_2.png) [@Almindor](https://forums.sifive.com/u/Almindor)\
**Post date:** [May 16, 2019, 11:04pm UTC](https://forums.sifive.com/t/missing-led-mappings-in-metal-h/2336/4 "2019-05-16T23:04:05Z")

</div>

Yup the dev branch works fine. Thanks!

---

<div class="post-metadata">

**Author:** ![ckuehnel](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/ckuehnel/32/994_2.png) [@ckuehnel](https://forums.sifive.com/u/ckuehnel)\
**Post date:** [May 18, 2019, 8:59am UTC](https://forums.sifive.com/t/missing-led-mappings-in-metal-h/2336/5 "2019-05-18T08:59:07Z")

</div>

Is there a release date? I tried the Dhrystone with this branch but result is unchanged.
