Page 1 of 2

Problème GPS

Posted: December 1st, 2021, 3:44 am
by PIERREPEROU
Hello,
From a locality A to a locality B, in the locality B the gps captures some coordinates of the locality A before capturing the real coordinates of the locality B.
I carried out more than 10 surveys with the same Gps program, I did not have this problem.

here is the program :

PROC M001A

onfocus

// CONDITION DE RECHERCHE SIGNAL GPS

if visualvalue(M001A)=notappl then

gps(open);


if gps(read,360,15)=1 then
errmsg("GPS VALIDE: Latitude: %f, Longitude: %f, Altitude:%f, Précision: %f, Heure %d",
gps(latitude),gps(longitude),gps(altitude),gps(accuracy),gps(readtime));
M001A=gps(latitude);
M001B=gps(longitude);
M001C=gps(altitude);
M001D=gps(accuracy);
M001E=gps(readtime);

setproperty($,"Protected","Yes");

else
errmsg("GPS INVALIDE,vérifier que le GPS est activé et reprendre la recherche")
select("Reprendre la recherche",LANGUE);

endif;

else
gps(close);
setproperty($,"Protected","Yes");
endif;

{***********************************************************************************}

Re: Problème GPS

Posted: December 1st, 2021, 10:26 am
by sherrell
Hello Pierre,

I'm not sure if your message got truncated, but I don't see a question being asked. Are you saying your logic no longer works? If so, could you tell us what version of CSPro you're running?

Thanks,
Sherrell

Re: Problème GPS

Posted: December 1st, 2021, 10:42 am
by PIERREPEROU
Bonjour,
La version c'est 7.6.2 (24 june 2021)
Ma question est : pourquoi ce comportement maintenant, je ne sais pas c'est lié quoi ? est ce mon programme,
j'ai l'impression que le GPS renvoi les coordonnées de la lecture précédente.

Je ne sais pas lié à quoi ?

MERCI...

Re: Problème GPS

Posted: December 1st, 2021, 11:30 am
by sherrell
Hello again,

As soon as you include a "gps(read)" statement, that immediately attempts to retrieve the current location's coordinates, and therefore overwrites whatever remains in memory.

If you wish to capture the last coordinates taken (which corresponds to what you are calling locality A?), then you would have to make a "b = gps(readlast)" call using the "readlast" argument. If b=1, then you can retrieve the last known coordinates using the regular gps(long/lat) calls.

Here's the help page that explains all this, please let me know if it isn't clear, so we can update the documentation.

https://www.csprousers.org/help/CSPro/gps_function.html

Sherrell

Re: Problème GPS

Posted: January 29th, 2022, 8:12 am
by ares
Hi to all,

I am facing the same issue.

We are actually doing a cartography. For a cluster of 500 household, we got only 5 points.

For the first phase, we tough it was the tablet choose for the project (some tablets were not having problem and other started disturbing after a month.

We are at the second phase and we changed the tablets. We are having the same problems.
Also coordinates collected are not accurate.

Re: Problème GPS

Posted: January 30th, 2022, 3:02 pm
by sherrell
Hi Ares,

Could you tell us what version of CSEntry you're running (the latest, 7.7?) and what devices you're using?

If you'd like us to test it, feel free to post your zipped application here (with at least one case that allows us to reach the GPS function call without having to enter data), we can test it out. If you'd rather not post here, you can send it to us at cspro@lists.census.gov

Thanks,
Sherrell

Re: Problème GPS

Posted: January 31st, 2022, 3:34 am
by ares
I am using cspro 7.5
We were using "LENOVO TAB3 7 Essential"

Now we are using "LENOVO TAB M10 HD"

Please can i have an email adress where i can send the application?

Re: Problème GPS

Posted: January 31st, 2022, 8:43 am
by ares
This is roughly the program we are using for cartography

Re: Problème GPS

Posted: January 31st, 2022, 6:57 pm
by sherrell
Hi Ares,

Your program worked fine for me with regard to getting an accurate read. I entered 3 persons and got a reading each time, which gave me the same number up to the 5th decimal spot (the 100th thousand position).

I see when S07=1 your gps(read) call waits 2 minutes with no requested level of accuracy. No problem there. However, when S07=3, the gps is being restricted to a 10 meter area:

Code: Select all

if gps(read,300,10) = 1 then
You might want to remove the accuracy, or make it larger (20 for example), to see if that helps. Do you know which gps call is failing? When S07=1 or S07=3? Or are both failing equally?

On a side note, I got a run-time error several times. It looks like there's an invalid subscript reference in a few places. For example, on line 223 when this call is made:

Code: Select all

if S07B = S07B(curocc() - 1) and S07A = S07A(curocc() - 1) and S07C = S07C(curocc() - 1) then
if you're in row 1 of the roster there is no prior roster row to refer to.

Sherrell

Re: Problème GPS

Posted: February 1st, 2022, 3:50 am
by ares
Hi Sherrel,

I forgot to put accuracy back on each program. I was testing whether removing accuracy could change the situation.

I joint a file with result of cartography with a tablet. The first EA was ok, then it started disturbing. We tough it was only that tablet disturbing. Later other tablets had the same problem.