AthStitcher: Now a DBMS
appdev wpf entity-framework ef database sqlite csharp athletics photofinish
The AthStitcher app has been extended to use a local Sqlite database to store the results of athletic meets. The app is written in C# using WPF and Entity Framework (EF) for the ORM.
Previously the app just determined finish times of athletes by stitching parts of successive video frames into a representation of the finish line as a function of time. As each time was determined by clicking on an athlete in the time sequenced video, horizontal position maps to time, the individual time is noted and available for posting elsewhere. Only the last determined time was available in the app.
The app has no been extended to record such times in a complete DBMS. As an ORM:
- There are Meets
- A Meet consists of Events
- An Event has a number of Heats
- A Heat has Lane results
Meet
- Description/Series
- Meet Number (in Series)
- Date
- Location
Event
- Start Time
- Age Grouping
- Age group
- Track Type
- Distance
- Lanes to be used (Max/Min i.e. First/Last)
LaneResult
- Lane Number
- Bib Number
- Name
- Time
- Status
- If DNS or DQ
The AthStitcher DBMS Entities
The app allows the user to enter a Meet, then Events within that Meet, and finally select the number of Heats for an event. Lane results for each Heat are generated from the Photo Finish API as discussed in previous blogs. The user can enter the results of each athlete in a lane as they are determined from the video.
Athletes
Athletes are currently entered as a name and possibly a Bib Number. The app allows the user to assign athletes to to a result as determined. A further entity could be added to the DBMS, namely Athlete, with Bib No against Name This makes entry of athletes simpler, whether before or after the event, as a search based upon Bib Number would be used.
Another possible entity is Location which would be a tabulation of Athletics tracks Names and Locations.
Apart from the app having a local Sqlite file as the database, there is currently no import or export of the DBMS data. It would be desirable to have the ability to import a Meet’s Program and to export results.
The app is available on GitHub at AthStitcher as part of the PhotoTimingDjaus Repository. The app is written in C# using WPF and Entity Framework (EF) for the ORM. The Sqlite database is created on the first run of the app, and the user can view and edit the data through the app’s interface.
| Topic | Subtopic | |
| This Category Links | ||
| Category: | Application Dev Index: | Application Dev |
| < Prev: | NuGet | Managing Package Versions in an app - Directory.Packages.props file |