Setting start radius of needle in lv_meter

With lv_meter there is the ability to create multiple meters which is the idea of what is wanted except without the taper. when using the normal needle style indicator needle the needle is the same width from start to stop but there is no way to set the start radius only the end radius and it always starts in the center. When using the add_arc function it allows you to select where the outer radius is and then how wide the arc is and this sets the inside radius. then using the set_indicator_start_value and the set_indicator_end_value functions you can create a narrow needle but the needle is tapered and not the same width. the closer it gets to the center the narrower it gets.

Having the ability to set the outside radius and then the length of the needle starting from the outside radius and heading to the center would allow for creating needles that look like this


and also ones that have a needle that overhangs the center and looks like this

and using the wonderful world of alpha channels and laying widgets on top of each other coupled with a canonical gradient image set as the indicator of an arc widget you can end up with a result like this


Rendering the canonical gradient real time is not something an MCU is going to be able to do with any kind of decent speed and it is best to use an already made one as an image. So I am not going to suggest that and using static images and lv_arc with the indicator set to use the image would work just fine for this kind of a thing. It’s the taper that would cause it to not look proper.

In all reality the needle should taper to the outside radius. That brings me to another portion of the feature request, adding an enumeration so a user can specify if they want no taper, taper to the outside or taper to the inside.

That same enumeration should also be applicable to the tick marks.
Adding the ability to set an image to the tick marks would allow a user to apply a gradient to them.

Being able to set the image to the tick marks and setting the taper of the tick marks would allow gauges like this to be created.


and here is an example where the needle is tapered to the outside and not the inside.

Couple more options added to lv_meter and a really cool gauge can be created when combining it with static images and lv_arc.


You can easily hide the taper. See in this example.

For v9 (the next major version) I have a couple of ides to make the meter simpler still more versatile. Until that I suggest using a small needle image where you need a needle more complex then a single line.