Jump to content

You're browsing the 2004-2023 VATSIM Forums archive. All content is preserved in a read-only fashion.
For the latest forum posts, please visit https://forum.vatsim.net.

Need to find something? Use the Google search below.
PLEASE READ - Webmaster Support Forum
This forum will be retired in the near future. Please direct all queries to our dedicated GitHub support page https://github.com/vatsimnetwork/developer-info/discussions 
Here you can find documentation on our services and we are continuing to migrate pertinent information into the Wiki pages https://github.com/vatsimnetwork/developer-info/wiki

Character Encoding of vatsim-data.txt


David Zhong
 Share

Recommended Posts

David Zhong
Posted
Posted

I get weird symbols when processing vatsim-data.txt depending on encoding (see picture below). What character encoding is everyone else using?

 

My primary concern at the moment is the line delimiter for controller info. My http library gives me 0xFFA7 (wchar) but it is displayed in my browser as 0xA7.

 

http library (stores as std::wstring/wchar_t): 9024857160.png

 

Browser (chrome): a5d3a915ba.png

David Zhong

Link to comment
Share on other sites

Mike Evans
Posted
Posted

The latter is what the data server spits out.

Mike Evans

Link to comment
Share on other sites

David Zhong
Posted
Posted

Thanks Mike. Time to wrestle with the library

David Zhong

Link to comment
Share on other sites

David Zhong
Posted
Posted

Found the bug in the library. Apparently signedness is important when doing type casting.

 

Speaking of libraries, it might be worthwhile to collect libraries for processing the data server output on the gitlab. A quick search only finds one (apparently) unmaintained php library, which indicates that everyone is "rolling their own" which (a) is a waste of time and (b) more importantly, increases the chance of applications not following the rules. What are the chances of providing limited public access to the VATSIM gitlab?

David Zhong

Link to comment
Share on other sites

 Share