Can't get example dial indicator to display any value

Discuss PC Developer and Web Developer projects and features here.
Post Reply
canary_wharfe
Posts: 105
http://meble-kuchenne.info.pl
Joined: Thu Dec 10, 2020 3:54 pm
Has thanked: 6 times
Been thanked: 12 times

Can't get example dial indicator to display any value

Post by canary_wharfe »

Have two files (attached) No.1 and No 2. File 1 is an example tutorial file from Matrix containing custom graphics/objects. Have copied the dial indicator from file 1 into a test file 2 which has a loop with three vars of different types and values. When run I'm expecting the dial to show the graphic value but zilch. The other digital display on the same 2d panel works so what I'm I missing? Is there some sort of source code these custom dials need? They are not in the standard list of components so just wondering if there's something missing - other than my brain that is :-)
Attachments
1_WebApp_MQTT_Client_Demo.fcsx
(63.34 KiB) Downloaded 6 times
2_Abs_Gauge.fcsx
(14.63 KiB) Downloaded 7 times

Steve-Matrix
Matrix Staff
Posts: 1509
Joined: Sat Dec 05, 2020 10:32 am
Has thanked: 211 times
Been thanked: 350 times

Re: Can't get example dial indicator to display any value

Post by Steve-Matrix »

You can copied the gauge from a Web Developer project into a PC Developer project. In general, Web Developer components are very different to PC Developer and Embedded Flowcode components and so you can't use them in the wrong type of project.

For a PC Developer project, you need to use a different gauge component - it's the "Circular Gauge" under "Indicators..Analog Indicator".

Or if you intended to create a new Web Developer project, you will need to start again and choose a "New Blank Web Developer Project" from the App Developer tab.

canary_wharfe
Posts: 105
Joined: Thu Dec 10, 2020 3:54 pm
Has thanked: 6 times
Been thanked: 12 times

Re: Can't get example dial indicator to display any value

Post by canary_wharfe »

Thanks for the info. That makes sense now. I have compared the properties of the analog circular gauge within a PC app vs Web app and it looks like the version in the PC app doesn't have all the customisable property attributes that the Web developer app has. The coloured ranges and number of range settings are missing although I see there is now an added Gauge::sMainImage and a Gauge::sCapImage. When you click on the small grey down arrow to the right of these labels a window pops up with 'Browse' in a small font. Then when you click on that word you get the standard Windows Open File Name display but there's no indication what type of file it's looking for? Presumably a graphic file but what format graphic and a graphic of what? A custom switch image? Can you get the coloured ranges option of the web developer now locked into a custom graphic file on the PC developer? Just need a little guidance on this. Thanks again for your assistance.

Steve-Matrix
Matrix Staff
Posts: 1509
Joined: Sat Dec 05, 2020 10:32 am
Has thanked: 211 times
Been thanked: 350 times

Re: Can't get example dial indicator to display any value

Post by Steve-Matrix »

The "Circular Gauge" component is deliberately cut-down to make it easier to use. The files for the images should be image files (png, bmp, etc).

Alternatively, you could use the base gauge component as this has some built-in range settings. It's complicated to use and is hidden. To find it, click the "Creation" component tab while holding down the Ctrl key. It will show as "Gauge" and can now be added to a 2d panel. There is a property at the bottom of the list for setting the coloured ranges. Many other aspects of the gauge can also be altered.

Feel free to use this hidden Gauge component, but be aware that it can be complex to set up and we don't offer much support for it.

canary_wharfe
Posts: 105
Joined: Thu Dec 10, 2020 3:54 pm
Has thanked: 6 times
Been thanked: 12 times

Re: Can't get example dial indicator to display any value

Post by canary_wharfe »

Hello Steve. So you're confirming the 'image files' property's purpose is as I assumed for loading a custom image of a dial face then? That would be just the circular dial face without the pointer?

Steve-Matrix
Matrix Staff
Posts: 1509
Joined: Sat Dec 05, 2020 10:32 am
Has thanked: 211 times
Been thanked: 350 times

Re: Can't get example dial indicator to display any value

Post by Steve-Matrix »

Yes, you can have custom images for the face of the gauge and the central 'cap'.

The attached is an example I did a long time ago (for v9). It uses the "Gauge" primitive rather than the "Circular Gauge" component, but the principle is the same. One of the gauges has custom images.
Attachments
gauge examples.zip
(223.92 KiB) Downloaded 8 times

canary_wharfe
Posts: 105
Joined: Thu Dec 10, 2020 3:54 pm
Has thanked: 6 times
Been thanked: 12 times

Re: Can't get example dial indicator to display any value

Post by canary_wharfe »

Brilliant! That should help see the principle of the process. Thanks again Steve.

Post Reply