Windows utility to set Hikvision Image Parameters Switch Scenes based on local sunrise sunset times

one big issue that i have is trusting unknown exe

why 163mb file to do what you are describing? i dont understand
ha ok, i think you did a publish into one file which include every dependency

anyway, i was able to decompile it and take the code from the form1 file and when compiled, it is a 140kb exe / 33kb dll (the exe isnt really needed in .net core world since you can run the dll)
 
I completely understand and agree with you... I'm not sure I would trust an unknow exe myself... would depend on how important it was to me to try the exe and more importantly the nature of the machine/network I was using...

I'm running a bit behind with the holidays, but I intend to upload the source code for this and another project I have to GitHub (I haven't used GitHub before so that's the delay) ... then the project could be downloaded and compiled by those who prefer that...

As far as the file size I think because I create a standalone exe using Visual Basic there are DLL files that are included in the exe which increase it's size.
if you need help let me know, i can spend sometime on this

i got my own set of tool, can be found here; GitHub - Spirch/BasicIpCameraSnapshot: Basic web application that request pictures from ip cameras and return a grid view of them

web app that you can connect to to download live snapshot image / download playback file (that one is a little bit obscure to use)
web app that let you control ptz (calling preset) and view the image after a delay
update textoverlay from weather site
 
i got my own set of tool, can be found here; GitHub - Spirch/BasicIpCameraSnapshot: Basic web application that request pictures from ip cameras and return a grid view of them

web app that you can connect to to download live snapshot image / download playback file (that one is a little bit obscure to use)
web app that let you control ptz (calling preset) and view the image after a delay
update textoverlay from weather site

Are they all for Hikvision cameras? I will check them out... right now I'm going to finally try to get started with GitHub.
 
Are they all for Hikvision cameras? I will check them out... right now I'm going to finally try to get started with GitHub.
yes all hikvision, feel free to look at the code, it's there and public for that :)

if anything is missing let me know, i just pushed the code, i might have forgotten to explain the appsetting structure
 
  • Like
Reactions: johnfitz
Then you didn't find anything nefarious/alarming/unexpected! :)
i did a quick scan and nothing jumped at me ;)

i would suggest to just publish without a single file and provide the app itself and not the dependency

let people handle that part, just explain what they need to install from microsoft

one issue is the included/embedded dependencies can become obsolete / vulnerable overtime
 
  • Like
Reactions: johnfitz
As far as I can tell, .net core still does not have any first-party GUI framework that works on linux. You'd have to learn something like this instead to build the user interface. GitHub - AvaloniaUI/Avalonia: Develop Desktop, Embedded, Mobile and WebAssembly apps with C# and XAML. The most popular .NET Foundation community project. I tried a couple years and did not get very far.
that is why when i can, i do my app under a webapp instead of a winform

beauty of this, i can run the app from linux or windows (even mac or arm i think) on a mini pc / external pc and remote connect to it

web is universal

right now i do everything with blazor, i started with mvc and i am planning to move what i have done under mvc to blazor

it "behave" like a winform but as a webapp
 
  • Like
Reactions: johnfitz
that is why when i can, i do my app under a webapp instead of a winform

beauty of this, i can run the app from linux or windows (even mac or arm i think) on a mini pc / external pc and remote connect to it

web is universal

I like building apps that way too. Unfortunately I also like making things that are small and light weight and user friendly all at the same time, and that is hard to do when you need a modern web browser engine to run the GUI. Like my PingTracer app -- it is just a 210 KB executable that runs on very little memory (by modern standards) and that is only possible because I used old .NET framework (not Core) with Winforms. If it needed to run in a web browser, I could probably still pull off a similarly small file size but the memory usage would be many times higher being in a browser, and the user interface would be super inefficient because of having browser tabs, address bar, misc buttons, bookmarks bar, etc all permanently stuck to it. It just would not be anywhere near as good of a utility that way.
 
  • Like
Reactions: johnfitz
being in a browser, and the user interface would be super inefficient because of having browser tabs, address bar, misc buttons, bookmarks bar, etc all permanently stuck to it

Just trying your PingTracer app... it is very nice/clean.
 
  • Like
Reactions: bp2008
Set this up at my house. Could get the cams to populate and all seems fine. Other than cam name doesn't come across. Says camera 1 I think it was on all cams. The monthly times work for me though. Put in an offset and saw it adjust in image parameters.

Some reason the work cams don't respond to this utility. In all fairness I think the four older cams at work barely have anything to adjust. As in they only have I think it's called scheduled-switch only. No image parameters.

UPDATE, I was correct. The 2 newer cams have image parameters capability and WORK with your app. Also these 2 work cams, the cam name comes across in your utility. Cams must have image parameters for this to work.
 
  • Like
Reactions: johnfitz
Cams must have image parameters for this to work.

I didn't have a great variety of cameras to test with... would be better if the utility was smart enough to know the if the camera doesn't have an image parameters switch (actually, I thought I had accounted for that) ... I think I'll get an old used camera on eBay so I can get it right...

4 each DS-2CD2347G1-LU
V5.6.820 build 220519

Just to confirm... this ^^^^ is the model/firmware that gave error 403?

Thanks for testing and figuring this out!
 
  • Like
Reactions: 0460dirt
I didn't have a great variety of cameras to test with... would be better if the utility was smart enough to know the if the camera doesn't have an image parameters switch (actually, I thought I had accounted for that) ... I think I'll get an old used camera on eBay so I can get it right...



Just to confirm... this ^^^^ is the model/firmware that gave error 403?

Thanks for testing and figuring this out!
Yes those 4 are a bit older and lack image parameters.
 
  • Like
Reactions: johnfitz