LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Has anyone made a dart scoreboard for cricket?

I'm looking to find or make a scoreboard for darts... mainly cricket. Has anyone already made one or have advice on how to construct the dart board so that the user can click on were they hit the board and the program will adjust the score appropriately?

Thank you,

Gene
0 Kudos
Message 1 of 7
(5,492 Views)
You can do this fairly easily using the picture control VIs (Graphics & Sound palette).

You can use the VIs to draw the necessary circles and lines. Then, you need to use an event structure with a mouse down event. This code in the event case will only execute when the mouse was clicked while on the picture and will return the coordinates of the click (in VI coords). You then need to calculate the position of the click in the picture and determine if it is inside one of the circles (and which).

Attched is a quick example (7.0). Note that only one circle is used and that 7.1 has a bug if you try to make the caption visible if it wasn't manually made visible at least once. The label and caption affect the indicator's position, which is why they are hidden.

___________________
Try to take over the world!
Message 2 of 7
(5,485 Views)
What screen size do you want to run this application at?? I'm running at 1280x1024.
Message 3 of 7
(5,476 Views)
Here is a rough start with a picture indicator and radio buttons.
Message 4 of 7
(5,475 Views)
Here some more foder to work with.

It is the source that was used to demonstrate "Ugly code" in the first Good, Bad, and Ugly show.

It is intended to analyze disk usage but can be changed.

It was also written before the event structure so the picture has to be "polled" for mouse clicks.

Like I said, UGLY!

Ben
Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 5 of 7
(5,459 Views)
Here is another dartboard with the mouse coordinates used to show which ring the mouse is in. I'm still working on the wedge detection.
Message 6 of 7
(5,452 Views)
Here is the rest of the vi with the mouse also selecting the number range for where the dart landed. I didn't put any scoring into the vi.
Message 7 of 7
(5,444 Views)