OpenALPR Tool - Save and Query CSV Exports

kheiney

Getting the hang of it
Joined
Nov 17, 2014
Messages
46
Reaction score
26
Removing the Date Range fixes the issue but it makes load times long becuase you are loading the entire database. It looks like the MaxDate has a bad value. This is what I did that fixes the issue. Just add a line to set the MaxDate. Now it loads quick with just 1 day of data populated.

/Set Date Ranges

dtp_Start.MaxDate = DateTime.Now.Date.AddDays(1).AddSeconds(-1);
dtp_Start.Value = DateTime.Now.AddDays(-1);
dtp_End.Value = DateTime.Now;
 

Gymratz

Pulling my weight
Joined
Jun 24, 2017
Messages
114
Reaction score
130
Perfect. That is exactly what the published code is supposed to do (and does for me). This is exactly why this isn't for someone afraid of code. It isn't a refined masterpiece lol! Go in and make edits to work as works for you.
 

riluxg

Getting the hang of it
Joined
Aug 1, 2015
Messages
63
Reaction score
26
Location
UK
Thanks to Gymratz for sharing this i have had it working for a few days and it was great but it has stopped working



Lpr Downloader



IF i manually download the csv files from openalpr it works and puts them into the database.

But if I use the start auto downloads I get imported 0 and skipped 0.



Lpr Viewer



When I start the viewer I get an unhandled exception Error converting date type nvarchar to datetime click continue and the viewer loads

but when I click Today or All I also get an unhandled exception of 06/01/2019 is not valid for value value should be between mindate and maxdate,

If I select the dates I get nothing showing in the database viewer



I have tried kheiney fix for the set date ranges but still the same



Any help or pointers would be appreciated



Once again thanks to Gymratz for sharing this
 

tech101

Known around here
Joined
Mar 30, 2015
Messages
1,472
Reaction score
2,125
Location
SF BayArea, USA
Wow I want to get this up and going but first .. Thank you so much for making this happen This is so useful thank you ! I wonder how I missed this post earlier..
 

sorka

Pulling my weight
Joined
Aug 9, 2015
Messages
366
Reaction score
197
Has anyone attempted a local solution by compiling the openalpr library into a windows app that handles the captures locally? This would make the response far faster and would allow us to send http requests to local devices running TTS servers. If the internet is down, you'd still get whole home voice notification of non white listed license plates.
 
Joined
Jul 13, 2019
Messages
12
Reaction score
1
Location
Pickerington, OH
I have a question concerning setting up the OpenALPR agent on the machine. What option do I choose when configuring for this to work:
OpenALPR Cloud
On-Premise Web Server
Other HTTP Web Server
Local Queue

I have walked thru 90% of the setup and left at this step. Currently I have another PC running the agent with my only LPR camera currently. This is actually running on the Blue Iris server but is causing CPU to get taxed a lot. Just need to get the last piece configured so I can get this up and running.
 

Fubduck

Getting the hang of it
Joined
Jul 10, 2018
Messages
109
Reaction score
72
Location
colorado
This tool is designed to use the OpenALPR Cloud option as far as I know.
 

bam2413

Getting the hang of it
Joined
Nov 6, 2019
Messages
52
Reaction score
41
Location
Minnesota
I think I am running into the same problem as Nyghthawk was, it seems like the downloader is both skipping plates and not importing anything...Nyghthawk feel free to chime in on how you overcame the current issue I am experiencing on your local machine. Thanks!

Interestingly, when I view the table data from the "PlateHits" table in SQL Server Management Studio, I can see that the downloader has in fact worked, just not sure why is says "0" for import on every download.


Well I think I finally got it all working. Goes to show if I can set this thing up anyone can.

Couple final questions (probably stupid, but I am going to ask),

  • Do I have to run two instances of visual studios now 24/7, or is there a way to now build these working standalone applications into programs I can install i.e .exe
  • I saw it mentioned I should increase the allowable storage space for plate images, where is this in the advanced Agent settings? 'Max Image Storage" is not an option that exists in my advanced settings
Thanks again to the guys who created this!
 

Attachments

Last edited:

DLONG2

Known around here
Joined
May 17, 2017
Messages
763
Reaction score
454
Hi bam2413. With Visual Studio, once you've 'File/Save All' then go to the 'Build' menu where you can then 'Build the Solution' into a standalone EXE program. Then look in the folder of the project name and in the 'bin/Debug' folder for the EXE file. That would be the one to run instead of Visual Studio. Just run Visual Studio if you need to watch or change the code.

For expanding on the available storage for capture images, that is found in the OpenALPR agent client, in the 'Configure / Agent Settings / Advanced / store_video_maxsize_gb' as I believe.
 

bam2413

Getting the hang of it
Joined
Nov 6, 2019
Messages
52
Reaction score
41
Location
Minnesota
Interestingly
Hi bam2413. With Visual Studio, once you've 'File/Save All' then go to the 'Build' menu where you can then 'Build the Solution' into a standalone EXE program. Then look in the folder of the project name and in the 'bin/Debug' folder for the EXE file. That would be the one to run instead of Visual Studio. Just run Visual Studio if you need to watch or change the code.
DLONG2

I've been going line by line through YOUR code feeling like I am in the damn movie Antitrust for the past few days to get this to work, so I appreciate your humble instruction with this as I felt it was probably a stupid question! Props to you fellas for the time you spent on this. I owe you both a beer!
 

DLONG2

Known around here
Joined
May 17, 2017
Messages
763
Reaction score
454
When you run the EXE program you had created in VS, there's a default icon used. You can choose your own icon for the program, but there are two places to tag the icon in VS:

1. Click on a part of the Form and look at the Form properties, for the 'icon' property setting. There you can click in and navigate to the icon of your choice, but you first need to find (or create) an icon first. That will then show as the icon of the form.
2. To change the default icon for the EXE program, go to 'Project' menu, and at the bottom of the pop-up list choose the last item which will be the project name's properties you have opened. Then in the Project Properties dialog, the 'Application' category should be selected on the left. Look for the 'icon' dropdown and then select the <Browse..> option. Then navigate to the icon of your choice stored somewhere on your PC.

SaveAll and Build Solution, and then your application will have a new icon.
 

bam2413

Getting the hang of it
Joined
Nov 6, 2019
Messages
52
Reaction score
41
Location
Minnesota
Last question how hard would it be for me to create a splash screen for when the programs are opening.
 

DLONG2

Known around here
Joined
May 17, 2017
Messages
763
Reaction score
454
You can add a splash screen by again looking at the Project menu, select 'Add Windows Form..' and in the Common Items category about half way down the list is 'Splash Screen (Windows Form)'. There you can design the splash screen as you wish. In the 'Project' menu, again at the bottom item for the project properties, in the 'Application' category, there's a drop-down for 'Startup form'. You would choose the splash screen instead of the Form1.

To get the splash screen to unload itself and to launch the Form1 takes some coding, though. Please google for the few lines of code needed and let me know if you need any assistance.
 

bam2413

Getting the hang of it
Joined
Nov 6, 2019
Messages
52
Reaction score
41
Location
Minnesota
Will do, gives me something to do the next few days off. Thanks Dlong
 

DLONG2

Known around here
Joined
May 17, 2017
Messages
763
Reaction score
454
I revisited the design and discovered how easy it is to add a splashscreen. First you would add a splash screen as described above. Then in the 'Project / (project name) Properties' menu item, in the 'Application' category, the Startup Form will remain the main Form1, or whatever name you set for it. But lower in the 'Splash screen' setting, select the splash screen which you had previously added. Compile and run, and without any code, the splash screen will stay loaded until the Form1 is finished loading.
 

bam2413

Getting the hang of it
Joined
Nov 6, 2019
Messages
52
Reaction score
41
Location
Minnesota
Nice thanks Dlong2 --

When I go to the project menu > Add Windows Form, I don't see any option in the list that has Splash Screen. Is this something I would have to install?
 
Last edited:

DLONG2

Known around here
Joined
May 17, 2017
Messages
763
Reaction score
454
In the Project menu, Add Windows Form, and in the 'Installed' category on the left, and in the 'Common Items' sub-category, there is no 'Splash Screen' listed on the right? Which version of Visual Studio are you running? Even so, you ought to be able to add a plain Windows form, making sure to make the ControlBox=false in the form's properties, and then change the Startup settings as above. Any form can be made into a splash screen, I believe.
 

hndymann

n3wb
Joined
Aug 21, 2018
Messages
8
Reaction score
6
Location
Helena AL
DLong and Gym, thank you so much for your hard work on this. Everything works great once I figured out how to use GitHub and make a few tweaks to OpenAlpr settings.
Quick question for you. The alerts, do they get pulled from OpenAlpr or am I missing some sort of configuration in the program to set alerts for particular tags and/or groups?
I see an Alert? Box on the viewer but am not sure if something is supposed to go in there?

Thank you

Luke
 
Top