navit-project.org

forum for navit navigation tool
It is currently 25 Jun 2017, 10:36
View unanswered posts | View active topics


All times are UTC


Forum rules


Feel free to ask anything here related to the installation and configuration of Navit.

Some notes before your first post:

Please provide as much informations as possible:



Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: ETA with formatting
PostPosted: 11 Feb 2014, 18:41 
Offline

Joined: 07 Feb 2014, 21:11
Posts: 5
Hello,

I am creating a custom layout and when I use the ETA string in my "text" OSD type element.

${navigation.item.destination_time[remaining]}

The problem is that this is not formatted per my local and does not use my timezone offset. I see that regular time has a way to format with :
vehicle.position_time_iso8601[string]

where Current GPS time with formatting string: { iso8601 | [ local; | offset ; ] format }
local; retrieves the timezone setting of the system
offset is a literal offset such as +02:00 (sign, hours, colon, minutes)
format is a time format string which follows the syntax for the C strftime function

Is it possible to format the ETA?


 Profile  
 
 Post subject: Re: ETA with formatting
PostPosted: 11 Feb 2014, 21:04 
Offline
User avatar

Joined: 07 Jun 2013, 17:13
Posts: 146
Location: Tartu, Estonia
tommycw1 wrote:
${navigation.item.destination_time[remaining]}

This is in fact not the arrival time, but the remaining travel time measured from the current time. You are probably looking for ${navigation.item.destination_time[arrival]} instead. I just had a look at the code for this, but it seems like there is no formatting option implemented for this right now. I can try to implement this when I have some time, but the code handling this looks a bit weird and it may take a while.


 Profile  
 
 Post subject: Re: ETA with formatting
PostPosted: 11 Feb 2014, 21:51 
Offline

Joined: 07 Feb 2014, 21:11
Posts: 5
Ah, yes, sorry - I did mean ${navigation.item.destination_time[arrival]}.

Would be great if you could have a look. Hopefully it isn't too crazy.


 Profile  
 
 Post subject: Re: ETA with formatting
PostPosted: 12 Feb 2014, 08:04 
Offline

Joined: 14 Jun 2013, 11:02
Posts: 24
be careful iirc one of those times is calculated according to the system time! - the other one with the time received by GPS - that made me crazy some time ago, telling me f.i. at 12:00 to arrive in 5min at 12:08...


 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Silver Orange 2.0.6 for IPB Designed by Skins and Hosting
Converted for phpBB3, based on Royal Blue template by BigB © 2007 2008 AEON KINGS