GPS only - troubles with latest version

Development & General Chat for the superb openxvario project.

Moderator: rainer

Post Reply
synekvl
Posts: 4
Joined: Sun Feb 02, 2020 6:53 am
Country: -

GPS only - troubles with latest version

Post by synekvl »

Hi guys,

I have a problem with the latest version of openXsensor. I use IDE 1.18.10 for compilation to Arduino Mini Pro. I'm able compile, flash and work with version 8.02 from February 2017, but I can't with version 8.2.13.

There is difference in compiled size while old one has 13412 bytes and the new one 6044 only with same GPS only enabled in config. I have Setup printouts in serial monitor after reflash in old, but no response in the new (of course with no GPS connected)...

I have made the config files using openXsensor Configurator 1.0.2 (see attachement) but without any result. I'm afraid that I haven't enabled all necessary parts of the code (because so huge difference in compiled size) but I can't what is wrong.

Do you have any ideas what I'm doing wrong ??

Thank you in advance
Vladimir
Attachments
oXs_config_advanced.h
(492 Bytes) Downloaded 265 times
oXs_config_basic.h
(556 Bytes) Downloaded 256 times

mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: GPS only - troubles with latest version

Post by mstrens »

Thanks for reporting a bug.
I will look at the issue.
mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: GPS only - troubles with latest version

Post by mstrens »

I do not think there is an issue in the code of latest oXs version even if the size is reduced.
Please note that I did not test with a real device and so I am not 100% sure.

The fact that you do not get anything in the serial monitor is normal. It is because the option "DEBUG" is not activated by default in the new version.
This option is normally useful only for a developper to debug the program.

I expect that I had forgotten to deactivate it in an old version.
I expect also that in the old version, there where several places where the program had to send messages to the serial monitor and that increases the size.

I noticed one inconsistency in the config files that you use: in config_advanced, you have those 2 lines

#define FILL_TEST1_WITH_GPS_NUMBER_OF_SAT
#define FILL_TEST2_WITH_GPS_HDOP

If you really want to get those 2 data you have to specify the fields to be used to send TEST_1 and TEST_2

Please check you device with an real receiver and transmitter (not with the serial monitor) and let me know if it works or not.

Note : if you really want, you could change some lines of code in order to activate the DEBUG option and to ask for sending some informations to the serial terminal.
synekvl
Posts: 4
Joined: Sun Feb 02, 2020 6:53 am
Country: -

Re: GPS only - troubles with latest version

Post by synekvl »

Hi Michel (or better Master),

I obviously had to wait and check whether there are some data on TX-RX link instead to be confused by missing data in serial monitor. Of course, it works now... thank you for kick me on...

The main reason for new version was to get numer of satellites and HDOP in TX. Now I uncommented #define ACCX_SOURCE TEST1 and #define ACCY_SOURCE TEST_2 and I can get both values in TX.

As I have to apply some strange coeficient 255 for TEST1 in order to get value i.e 110 for 3D fix with 10 sats, I have a question - is there other better way how to prepare both data in code for Arduino ?

Nevermind, once again thank you for your job and answer to my questions.

Cheers
Vladimir
mstrens
Posts: 1435
Joined: Fri Dec 27, 2013 7:49 pm
Country: -

Re: GPS only - troubles with latest version

Post by mstrens »

ACC x, y z have a special handling in openTX (due to Frsky original sensor). The displayed value are the transmitted one divided by 100. That explains that you have to apply this strange coef.
To avoid it, you could send the 2 data as Temp1 and Temp2 instead of Accx and Accy. Fore Temp1 and Temp2, openTx just keeps the transmitted values unchanged.

synekvl
Posts: 4
Joined: Sun Feb 02, 2020 6:53 am
Country: -

Re: GPS only - troubles with latest version

Post by synekvl »

I don't know whether your suggestion to use Temp1 and Temp2 belongs to "#define T1_SOURCE TEST_1" and "#define T2_SOURCE TEST_2". Nevermind the SatN value is quite clear and for HDOP it is a question of time to find out how corresponds value shown in TX with calculated data.

Thank you for your time
Vladimir
Carbo
Posts: 467
Joined: Fri Aug 02, 2013 6:55 pm
Country: Germany
Location: Freinsheim RP

Re: GPS only - troubles with latest version

Post by Carbo »

255 is perfect, since it is 2.55 * 100
The ratio for factor 1 is:

Precision 0 --> 255 (Temp)
Precision 1 --> 25.5 (e.g. Current)
Precision 2 --> 2.55 (e.g. Acc)

Took me some years to find out :)
synekvl
Posts: 4
Joined: Sun Feb 02, 2020 6:53 am
Country: -

Re: GPS only - troubles with latest version

Post by synekvl »

Thank you Carbo for your hints... very usefull.... ;-)

Post Reply

Return to “OpenXVario - an open source vario supported by the open source firmwares!!”