mobile CCTV,mobile surveillance,police body worn cameras

标题: questions about smarteye WEB SDK/API [打印本页]

author: arie    time: 2024-11-8 17:33
标题: questions about smarteye WEB SDK/API
Dear …
We have a problem while trying to logon using the API’s {user logon} endpoint. So we have a question now.

Q1: Which documentation page correctly describes the login logic:

https://smarteye.besovideo.com/doc/bvcspapi/index.html
with password_encrypted = SHA256({username}_{password}) like “SHA256:6848d6405bf34bf9b2d82ed8822c756807632d3eaefedec90ac33cb32ac83671”

or

https://smarteye.besovideo.com/bvdoc/

with password_encrypted = SHA256( SHA256({username}_{password})_{timestamp} ) like “SHA256_T:ebc145ec6decbc3e7842f1fbc2bd6d0cf65e76f1dc3b7e21ebfd01a5c5a8c65a”

?

Even when I try both(!), I still get StatusCode=200(OK) but the JSON shows me an error like

{
    "code": 14
    , "msg ": "Password Error. remaining count:0"
    , "data":
        {"token": "_v0uoRImxxkTcwWnZ8_IYrw"
        , "timeout": 0
        , "appID": 0
        , "remaining": 0
        , "locking": 0
        , "change_password": false
        }
}

? What can be wrong here?

This is my C# code:




author: fanghj90    time: 2024-11-8 17:48
Q1: https://smarteye.besovideo.com/bvdoc/ 是最新的接口文档
看代码和数据都是对的,不应该返回账号密码错误,使用web客户端是否可以登录?密码123456是否正确
如果相同的账号密码web客户端可以登录,接口就是正常的,可以f12看浏览器发的请求参数
https://smarteye.besovideo.com/bvdoc/    is the latest document.
your source is all right, but try visit by the standard WEB URL to compare if  your user/passwd is correct, is your passwd is 123456  ?
if user/passwd is correct and standard WEB visit is ok, then pls show us info in F12 for us to check your parameters in URL request.

author: arie    time: 2024-11-14 02:56
Hi,
The API is working for us now so that is great.
Now we are busy with getting the live stream to work.

On our CMSV server we do the live streaming by a URL like this:
https://bodycam.mobiletrack.nl/8 ... eam=1&channel=1

How can we do this on your application?

We can not use the example because our programmers use C#

Please help us with this.

Kind regards

Arie

author: arie    time: 2024-12-5 16:44
Dear,

Can you please let us know how we can install the demo package. We tried the {npm install URL} but it did not work:


author: IBeli    time: 2024-12-5 17:05
arie post on2024-12-5 16:44
Dear,

Can you please let us know how we can install the demo package. We tried the {npm install U ...

Hi,
First  git clone https://gitee.com/besovideo/ewebdemo.git
Then Run npm install inside the dir

author: arie    time: 2024-12-6 03:55
Hi please help with this question from our developer:

Since we need to create 1 packed js file from all these Typescript/JS projects, please tell/show us what "build" command line in "scripts" should be used in the {package.json} file. We do not transpile, pack or bundle code files - we use plain simple Javascript. We are trying to make such a file to connect to the player.

THNAK YOU!
author: IBeli    time: 2024-12-6 10:00
arie post on2024-12-6 03:55
Hi please help with this question from our developer:

Since we need to create 1 packed js file fr ...

Hi
Did you mean that you want to call the api from player after using <scritp> element load a js file, just like use
the jquery?
author: arie    time: 2024-12-6 17:59
IBeli post on2024-12-6 10:00
Hi
Did you mean that you want to call the api from player after using  element load a js file, ju ...

Hi yes that is what we mean.
author: arie    time: 2024-12-6 18:07
arie post on2024-12-6 17:59
Hi yes that is what we mean.

We need to code the stream like this:

<script type="text/javascript" src="node_modules/@besovideo/webrtc-player/dist/main.es.js">
        let instance = new PuPlayer( { ... } );
        instance.open();
        instance.display();
        instance.play();
        ...
        instance.close();
        instance = null;
</script>

author: IBeli    time: 2024-12-6 18:15
arie post on2024-12-6 17:59
Hi yes that is what we mean.

Ok ok
After you loaded main.browser.js and main.browser.css, var bvPlayer (contains all exported apis) will mounted  in window, then call bvPlayer.xxx
See doc here: https://www.npmjs.com/package/@b ... er?activeTab=readmeYou can find those two file in https://www.npmjs.com/package/@b ... ayer?activeTab=code dist dir.




author: arie    time: 2024-12-6 18:16
arie post on2024-12-6 18:07
We need to code the stream like this:

So we need an (aspx) page with HTML like <div>'s, <canvas>, <button>'s etc and a <script> block.
author: coldflame    time: 2024-12-7 10:25
ok, pls have a try
author: arie    time: 2024-12-9 15:55
IBeli post on2024-12-6 18:15
Ok ok
After you loaded main.browser.js and main.browser.css, var bvPlayer (contains all exported  ...

Dear,

Can you please tell us how from this:  {https://84.22.96.184:9781}
we can receive this header: {access-control-allow-origin: 'https://84.22.96.184:9781'}.

And pleace replace the DOUBLE-BYTE codes by English translation since we need to read the errors and other texts!
Thank you very much!
  
See image:




author: IBeli    time: 2024-12-9 16:41
arie post on2024-12-9 15:55
Dear,

Can you please tell us how from this:  {https://84.22.96.184:9781}

Dear,
Did you mean you want to load main.browser.js from https://84.22.96.184:9781 to your website?
DOUBLE-BYTE codes unreadable is a problem, we will replace them in the next step.





author: arie    time: 2024-12-9 17:55
IBeli post on2024-12-9 16:41
Dear,
Did you mean you want to load main.browser.js from https://84.22.96.184:9781 to your websit ...

Hi yes that is what we mean.
author: IBeli    time: 2024-12-9 18:18
arie post on2024-12-9 17:55
Hi yes that is what we mean.

Hi,
As you konw main.browser.js is just a javascript lib, load it from  {https://84.22.96.184:9781} website is not necessary, just like jquery. Download it from npm and copy to your website, also there has some cdn provide the services CDN.
Beside, there is no main.browser.js  in the {https://84.22.96.184:9781} website.

All of above, Make your website load the lib in diff way.



Yes, you have posted [we can receive this header: {access-control-allow-origin: 'https://84.22.96.184:9781'}.], The CORS cause the issue.
If you want send a http request from your website to {https://84.22.96.184:9781} and get response suceess , Config CORS on {https://84.22.96.184:9781} is necessary.


author: arie    time: 2024-12-9 23:56
Hi dear,

We get an error (see picture)
How can we solve this?

author: arie    time: 2024-12-9 23:57
arie post on2024-12-9 23:56
Hi dear,

We get an error (see picture)
How can we solve this error?
[attach]3431[/attach]

Kind regards
Arie
author: IBeli    time: 2024-12-10 09:04
arie post on2024-12-9 23:57
Kind regards
Arie


Hi
Webrtc is incapable with video codec h265,main.browser.js has added ws-bvrtc for the incapability.
The key named “type” in the first parameter of function PuPlayer can indicate the protocol switching.
The type has there options "webrtc" | "ws-bvrtc" | "auto"
Have a try
author: arie    time: 2024-12-10 18:53
Both "auto" and "webrtc" cause the same {WebrtcH265Error} error! "auto" is the default so that would not work anyway.

When "ws-bvrtc" is set as {type}, we get this error: (see picture)




. Is this a <logical> error to change the code flow?

Please help with this. We are so close now i think.
author: IBeli    time: 2024-12-10 19:10
arie post on2024-12-10 18:53
Both "auto" and "webrtc" cause the same {WebrtcH265Error} error! "auto" is the default so that would ...

This exception throw is right, exception handle scope will do ws-bvrtc process, and will not throw upper.
Is there no video shown?

author: arie    time: 2024-12-10 19:23
IBeli post on2024-12-10 19:10
This exception throw is right, exception handle scope will do ws-bvrtc process, and will not throw ...

Thanks!

We also get this error/problem:
Can you tell us what todo to solve this?
We hope to get this working today.



author: arie    time: 2024-12-10 19:31
arie post on2024-12-10 19:23
Thanks!

We also get this error/problem:


author: arie    time: 2024-12-10 19:46

author: coldflame    time: 2024-12-10 19:54
addon an error picture
author: IBeli    time: 2024-12-10 19:59
arie post on2024-12-10 19:46

There has two questions.
1.Content Security Policy made the worker couldn’t be constructed
2.wss can’t connect to xxxxx:9702

Could you provide a todesk or other  Remote Desktop

author: arie    time: 2024-12-13 04:40
Hi question about the API:

Is it possible todo the following for you guys?

Put the {battery level} into the result of the {pu/list} endpoint instead of the {pu/power/battery/{puid}} SINCE that (a) takes additional request and (b) ONLY 1 per device as we need for ALL devices AT ONCE!
Same for the {pu/gpsdata/{puid}} which gives us the location. We need to get ALL of this AT ONCE, please!
So, if we have 10 cameras we need to make 1 request to get all the information instead of 1 + 10x + 10x = 21x !
This takes more time and uses a lot of resources as we need to get it each MINUTE!
author: IBeli    time: 2024-12-13 17:59
arie post on2024-12-13 04:40
Hi question about the API:

Is it possible todo the following for you guys?

Now thoes apis is not exist.
We can add those apis, if you pay for that.
You must know:
Get Battery lever of a list of pu, server will send to each of those pu, wait for every pu response, It will make the Get be slow.
Gpsdata request also.

author: arie    time: 2024-12-16 02:13
IBeli post on2024-12-13 17:59
Now thoes apis is not exist.
We can add those apis, if you pay for that.
You must know:

Hi,

We have a problem with the GPS position from the bodycams.
The bodycams have a good GPS position.
We can see that in the MCP app and in android.
But when we ask for the GPS position with "{pu/gpsdata/{puid}} endpoint" than the location is not good and not the same latitude and longitude as the real location.
What can we do about this?
author: IBeli    time: 2024-12-16 08:31
arie post on2024-12-16 02:13
Hi,

We have a problem with the GPS position from the bodycams.

Is the response location always not good?
There has a config on device to control the interval time of device post gps location.
author: arie    time: 2024-12-16 16:17
IBeli post on2024-12-16 08:31
Is the response location always not good?
There has a config on device to control the interval t ...

Hi we have set the interval time on 5 seconds (also tried 30 and 60 seconds)
(See picture 1)
We check the location in MCP (in Map) and that location is correct. (see picture 2)

But when we ask for the location it is the location from 60km away.
This morning i did a car drive for 60km (from home to work address)
On the device in MCP i can always see the good location.
We ask the API for the GPS latitude and longitude every minute but it is still at my home address.

So it seems that the bodycam has a good location but the MCP app does not send that location to the server.
What can we do for that? The location is very important for us!





author: coldflame    time: 2024-12-21 17:35
there is a calling sequence to obtain correct position on map per our talk in wechat.
any further problem, let's go on here.
author: arie    time: 2024-12-22 09:29
GPS problem bodycam:

We request the location of the bodycam every minute via the API with: {GET "pu/gpsdata/<puid>"}
This API command works well.
Only what we noticed is that the GPS position was very poor.
Until we discovered that the GPS position is perfect when the bodycam screen is on.
The same also applies to the besovideo VMS website.
There you will see that location only works good when the bodycam screen is on. (see video on WeChat from last Thursday)

This all has to do with the software on the bodycam in my opinion.
It seems like the GPS goes to sleep or something similar when the screen is off.

I hope you can fix this in the software. This is very important for our business case.

If this can be resolved, I promise that we will start with an order for 100 body cameras and also several IP cams.

If you need to adjust the MCP software for this, please let me know because we would like to have a few simple things adjusted in the BA280 MCP software.

--For example, never use the blue/red emergency lights for an SOS alarm

--Start recording when you create an SOS alarm.

--And slightly extend the time you can press the SOS button. Now to make an SOS you only have to press it briefly. If you press a little too long (for example 2 seconds), it will not sound an alarm. Users are used to having to press our other buttons for 2 to 3 seconds.

--And if possible, the MobileTrack logo instead of the Smarteye logo when starting the camera.

author: besovideo    time: 2024-12-22 09:40
pls enable GPS access always, while by default it's only in APP use, and it's not considered as in use while screen is OFF.
so pls make it always here.






欢迎光临 mobile CCTV,mobile surveillance,police body worn cameras (http://bbs.besovideo.com:8067/) Powered by Discuz! X3.2