Tracking Device Not Connecting

Omar Asim5 years ago

Hello People,

I have recently installed Traccar on my personal PC that is being acting as a server, I have created the account and added up the the mobile device with the identifier being mentioned in the traccar client application, I'm following the instructions and as told I'm trying to change the Server URL in the application with my public IP address it is giving me error which is "Please enter a valid http:// or https://". Kindly let me know the solution for it. In Logs of the client app location sending is failing.

Turbovix5 years ago

Let's see:

1 - I believe that because it is a public IP, it should be dynamic, so you need a DDNS (NoIP) service.
2 - You need to configure your modem / router by opening the necessary ports, in case of mobile (5055) and direct to the IP of your local server.
3rd - You need to enter the full URL: http://221.19.96.109:5055
or http://221.19.96.109

Omar Asim5 years ago

Hi Turpovix,

Thank you for your response. I have tried writing the way you've told me in step 3 but still it gives error sending failed. My public IP is 168.211.2.250
I have tried writing in the way http://168.211.2.250 and http://168.211.2.250:5055 but did not got the result what I was expecting.

As you have told in step 2 I have to open other ports also, so do you mean I should configure the port 5055 on the PC ? If yes can you please let me know how can I do that.

Turbovix5 years ago

I see that you no longer receive the URL error information, so the only flaw that exists now is connection. Therefore, you should allow a device outside your local network to access your server, basically you should do this by opening the required TCP ports, in case mobile devices is port 5055 that Traccar uses for these devices I advise you to open it too. port 8082. Generally you should open ports on both your modem / router and your operating system firewall.
Remember that your modem / router should direct these ports to the local ip of your Traccar server.

I suggest you use some service to test if the doors are really open.

https://www.yougetsignal.com/tools/open-ports/

Omar Asim5 years ago

Thanks Turbovix, issue solved.
Secondly do you know how can i change the logo being present over the login form, I have tried finding the code in login.js but couldnt reach it tho. Login.js file is not in the web folder.

Turbovix5 years ago

Just replace the image in traccar-web/web/logo.svg

Omar Asim5 years ago

Hi Turbovix,

I identified the file in web folder but can you please tell me where to update in the code to get the image i want, as I have read the code but still cant identify where it has been uploaded in code.

I also got login.js file by searching in the below directory :

C:\Program Files\Traccar\web\app\view

but i cannot identify the code that I should be editing to get the picture changed. I'm using the default icon.png picture to get updated just for testing purposes before uploading the original logo. Can you please tell which area should i be updating to get it done. I'm attaching a screenshot link of code i identified to be changed, I have updated the src with icon.png but still not change .

https://imgur.com/48yPT3p (this is of login.js)

Turbovix5 years ago

You checked in traccar-web/web/app/view/dialog/Login.js

Omar Asim5 years ago

Yeah Turbovix I checked over there and have attached an image in my last comment that shows the logo part only but changing the src doesnt gives any effect also.

I just checked by replacing the logo.svg file with converting my logo to svg file and uploading that to the web folder with the same name and now the result is it is showing nothing on the logo area.

Can i have your email, I can send you the files, i'll really appreciate the help.

Turbovix5 years ago

Now I understand what you meant.
You must generate the image with the extension .svg, ie it is a vector image!

Turbovix5 years ago

Note that any changes you make to the code, you need to generate a new app.min.js using the tool (traccar-web /tools/minify.sh) if you use Linux, otherwise use .bat, so the code change will have effect.

Omar Asim5 years ago

Turbovix should i save it with the same name as old one and delete the old one and would it adjust the height and width itself ?

Turbovix5 years ago

Exactly!

Omar Asim5 years ago

Hi turbovix,
can you please tell me how can I run the file minify.bat on my windows. Should i download the file over the same folder of traccar and then run it only and results will be shown over the web interface ?

Turbovix5 years ago

Compiling Web Interface
Web interface is written in JavaScript, so it generally does not require compiling. Release version of Traccar uses compressed version of web interface where all JavaScript are combined into one and minified. That's done for performance reasons.

Therefore changes made to the javascript code will require you to re-create a compressed version of the web interface. This is done using the script (minify.sh or minify.bat) found in the directory: / traccar-web / tools /.
I do not use Windows, on Linux it depends on (Sencha ext-6.2.0) and Sencha CMD installed, just call the script in the directory where it originates, once the script creates the (app.min.js) in the directory. / traccar-web / web, and you can enjoy the interface with your modifications.

https://www.sencha.com/products/extjs/cmd-download/

http://cdn.sencha.com/ext/gpl/ext-6.2.0-gpl.zip