PDA

View Full Version : zic2410 uart problem, nema gps demo


Kham
03-01-2010, 10:00 PM
zic2410 module running firmware 2.2.16 Debug
portal 2.2.29
gps module (http://www.sparkfun.com/commerce/product_info.php?products_id=465)

As soon as I connect the gps, well you can see what happens.
It does come back after a few seconds.

Program is the gpsNmea.py demo with minor changes for the zic2410 hardware pinout.


extract from docklight terminal program.
-------
reboot.Time: 0:0:0<CR><LF>
Latitude: 0d 0m 0s - None<CR><LF>
Longitude: 0d 0m 0s - None<CR><LF>
Altitude: 0<CR><LF>
0 sats, no fix.<CR><LF>
Assert failed: ..\..\..\Hardware\UartBuffer.c L271<CR><LF>
Assert failed: ..\..\..\Hardware\UartBuffer.c L271<CR><LF>
Assert failed: ..\..\..\Hardware\UartBuffer.c L271<CR><LF>



A possible workaround I will be trying is to disconnect the uart once the string of interest has been buffered.

kbanks
03-02-2010, 12:13 PM
That particular assert means you are getting too much serial data.


else
{
// Rx Buffer overflow
assert(0); // <- this is line 271 of UartBuffer.c
}


Are your UART timeouts set so that the data is pushed as soon as it's available? Or are they set too long, and multiple GPS messages are overflowing the receive space?

How many characters are you getting at one time in your HOOK_STDIN handler?

Kham
03-02-2010, 08:34 PM
Currently set to defaults. 5,75,0
So will tune and see.

This gps module does pump out a bit data, about 300 bytes/sec once it has got a lock.

I have also recoded the script to handle the incoming data quicker.
Using slicing rather than delimiter detection.
Crude but effective.

if len_tok == 74:
xlat_deg = curTok[18:27]
xlng_deg = curTok[30:40]
xnumSatellites = int(curTok[46:47])