Author Topic: ($40 GPSDO working well now, my mistake)  (Read 71917 times)

0 Members and 2 Guests are viewing this topic.

Offline pigrew

  • Frequent Contributor
  • **
  • Posts: 680
  • Country: us
Re: ($40 GPSDO working well now, my mistake)
« Reply #50 on: August 21, 2017, 03:53:55 am »
How does one get it into $KALDBG ?

Send "$KALDBG 1", and it'll output the $KALDBG message every 20 seconds. See my other post for details....

It seems that KAL1 is GPS time. KAL3 is of similar magnitude to the output ADC counts, but doesn't exactly track the ADC. KAL5 is a smoothed version of the phase error (roughly in units of 6ns). I'm unsure of the rest of the meanings.

To get the ADC counts, you have to look at the PPSDBG string.
 

Offline texaspyro

  • Super Contributor
  • ***
  • Posts: 1407
Re: ($40 GPSDO working well now, my mistake)
« Reply #51 on: August 21, 2017, 04:49:40 am »
Some more command are in this list (leading $ not shown):
  if     (!strcmp(msg_field, "CLOCK"))          parse_true_clock();
   else if(!strcmp(msg_field, "DISCARD"))        parse_true_discard();
   else if(!strcmp(msg_field, "ESN"))            parse_true_esn();
   else if(!strcmp(msg_field, "EXTSTATUS"))      parse_true_extstatus();
   else if(!strcmp(msg_field, "GETA"))           parse_true_geta();
   else if(!strcmp(msg_field, "GETBDELAY"))      parse_true_getbdelay();
   else if(!strcmp(msg_field, "GETDELAY"))       parse_true_getdelay();
   else if(!strcmp(msg_field, "GETPOS"))         parse_true_getpos(0);
   else if(!strcmp(msg_field, "GETP"))           parse_true_getp();
   else if(!strcmp(msg_field, "GETSCALEFACTOR")) parse_true_scale();
   else if(!strcmp(msg_field, "GETVER"))         parse_true_getver();
   else if(!strcmp(msg_field, "KALDBG"))         parse_true_kaldbg();
   else if(!strcmp(msg_field, "LEAVE"))          parse_true_leave();
   else if(!strcmp(msg_field, "PPSDBG"))         parse_true_ppsdbg();
   else if(!strcmp(msg_field, "PROCEED")) ;
   else if(!strcmp(msg_field, "SAT"))            parse_true_sat();
   else if(!strcmp(msg_field, "SET1PPS"))        parse_true_set1pps();
   else if(!strcmp(msg_field, "SPIW"))           parse_true_spiw();
   else if(!strcmp(msg_field, "STATUS"))         parse_true_status();
   else if(!strcmp(msg_field, "SURVEY"))         parse_true_getpos(1);
   else if(!strcmp(msg_field, "TRAIM"))          parse_true_traim();
   else if(!strcmp(msg_field, "UPDATE"))         parse_true_update();
   else if(!strcmp(msg_field, "WSAT"))           parse_true_wsat();

Also firmware dump attached...
 
The following users thanked this post: cdev

Offline nuno

  • Frequent Contributor
  • **
  • Posts: 606
  • Country: pt
Re: ($40 GPSDO working well now, my mistake)
« Reply #52 on: August 21, 2017, 11:57:32 am »
At the top center there's an inductor with the ferrite broken.
 

Offline CJay

  • Super Contributor
  • ***
  • Posts: 4136
  • Country: gb
Re: ($40 GPSDO working well now, my mistake)
« Reply #53 on: August 24, 2017, 09:12:54 am »
Just a quick post, the case I intend to repurpose for my GPSDO:

 

Offline cdevTopic starter

  • Super Contributor
  • ***
  • !
  • Posts: 7350
  • Country: 00
Re: ($40 GPSDO working well now, my mistake)
« Reply #54 on: August 24, 2017, 01:58:57 pm »
Nice!  I've been scouring the sites looking for something similar for not too much.

That's (re-purposing an existing case) definitely the way to go.

Something with BNCs, buttons, and an LCD ideally.
« Last Edit: August 24, 2017, 06:27:36 pm by cdev »
"What the large print giveth, the small print taketh away."
 

Offline cdevTopic starter

  • Super Contributor
  • ***
  • !
  • Posts: 7350
  • Country: 00
Re: ($40 GPSDO working well now, my mistake)
« Reply #55 on: August 25, 2017, 01:54:09 am »
Attached is what I got from running the Linux strings command on the file!

(27k) of strings. Unedited.



Quote from: texaspyro on 2017-08-20, 22:49:40
Some more command are in this list (leading $ not shown):
  if     (!strcmp(msg_field, "CLOCK"))          parse_true_clock();
   else if(!strcmp(msg_field, "DISCARD"))        parse_true_discard();
   else if(!strcmp(msg_field, "ESN"))            parse_true_esn();
   else if(!strcmp(msg_field, "EXTSTATUS"))      parse_true_extstatus();
   else if(!strcmp(msg_field, "GETA"))           parse_true_geta();
   else if(!strcmp(msg_field, "GETBDELAY"))      parse_true_getbdelay();
   else if(!strcmp(msg_field, "GETDELAY"))       parse_true_getdelay();
   else if(!strcmp(msg_field, "GETPOS"))         parse_true_getpos(0);
   else if(!strcmp(msg_field, "GETP"))           parse_true_getp();
   else if(!strcmp(msg_field, "GETSCALEFACTOR")) parse_true_scale();
   else if(!strcmp(msg_field, "GETVER"))         parse_true_getver();
   else if(!strcmp(msg_field, "KALDBG"))         parse_true_kaldbg();
   else if(!strcmp(msg_field, "LEAVE"))          parse_true_leave();
   else if(!strcmp(msg_field, "PPSDBG"))         parse_true_ppsdbg();
   else if(!strcmp(msg_field, "PROCEED")) ;
   else if(!strcmp(msg_field, "SAT"))            parse_true_sat();
   else if(!strcmp(msg_field, "SET1PPS"))        parse_true_set1pps();
   else if(!strcmp(msg_field, "SPIW"))           parse_true_spiw();
   else if(!strcmp(msg_field, "STATUS"))         parse_true_status();
   else if(!strcmp(msg_field, "SURVEY"))         parse_true_getpos(1);
   else if(!strcmp(msg_field, "TRAIM"))          parse_true_traim();
   else if(!strcmp(msg_field, "UPDATE"))         parse_true_update();
   else if(!strcmp(msg_field, "WSAT"))           parse_true_wsat();

Also firmware dump attached...
"What the large print giveth, the small print taketh away."
 

Offline cdevTopic starter

  • Super Contributor
  • ***
  • !
  • Posts: 7350
  • Country: 00
Re: ($40 GPSDO working well now, my mistake)
« Reply #56 on: August 25, 2017, 02:09:15 am »
Hmm.. in there it says "Hello from Nios II"

Nios II is an OS that runs on the Altera FPGA platform.

https://en.wikipedia.org/wiki/Nios_II

https://people.ece.cornell.edu/land/courses/ece5760/DE2/tut_nios2_introduction.pdf

https://www.altera.com/en_US/pdfs/literature/hb/nios2/n2cpu_nii5v1.pdf

It appears you talk to it via a USB Blaster cable.. (implemented with another Altera FPGA)

This is I'm sure what one of those headers is.

"What the large print giveth, the small print taketh away."
 

Offline Nuno_pt

  • Frequent Contributor
  • **
  • Posts: 435
  • Country: pt
Re: ($40 GPSDO working well now, my mistake)
« Reply #57 on: August 26, 2017, 08:48:10 pm »
Nice!  I've been scouring the sites looking for something similar for not too much.

That's (re-purposing an existing case) definitely the way to go.

Something with BNCs, buttons, and an LCD ideally.

The Extron are good boxes for this propose they have lot(s) of BNC(s) with the RGB channels for the 10MHz distribution amplifier, and the H/V channels for the PPS, some models are tall enough to put an LCD, see this box Extron ADA6 300MX https://gerrysweeney.com/tag/extron/
Nuno
CT2IRY
 

Offline cdevTopic starter

  • Super Contributor
  • ***
  • !
  • Posts: 7350
  • Country: 00
Re: ($40 GPSDO working well now, my mistake)
« Reply #58 on: August 27, 2017, 04:01:03 am »
You really are right about extron.

I have to say after reading all the problems some people have had buying other comparable GPSDO units - (Symmetricom, Trimble UCCM, etc) which were also removed from telecom service, I feel extremely lucky to have gotten a solid unit that works well. I'm not in any rush to do this, I just want to have a solid enclosure for it that protects it from harm and feeds it clean power and displays the basic facts about its operation.

I will use Lady Heather is for visual display of the more complex quantitative information..
« Last Edit: August 27, 2017, 04:10:01 am by cdev »
"What the large print giveth, the small print taketh away."
 

Offline pigrew

  • Frequent Contributor
  • **
  • Posts: 680
  • Country: us
Re: ($40 GPSDO working well now, my mistake)
« Reply #59 on: September 04, 2017, 07:55:52 pm »
I've stared trying implement a microcontroller-control program.

I settled on the stm32f103 as my target platform (using the blue-pill board). I have it working, along with one of the I2C 0.96" OLED displays. BOM cost is less than US$10 (board is $2.50, OLED is about $2.50, plus some wire and surface-mount resistors).

Current features:

* Sends $PROCEED when needed.
* Sends $PPSDBG 1 when needed.
* Displays UTC time of day, satellite count (from $EXTSTATUS), OXCO/board temperature, and lock status.
* Acts as USB serial-port, which forwards data the computer (I don't have data going the other way, yet).

I still have a few things left to do, but it's a good start.

Code at https://github.com/pigrew/trueposctrl.

I probably should add a button or two in order to be able to start a self survey, display satellite info, display lat/long info, etc.
 
The following users thanked this post: ZL1CVD

Offline cdevTopic starter

  • Super Contributor
  • ***
  • !
  • Posts: 7350
  • Country: 00
Re: ($40 GPSDO working well now, my mistake)
« Reply #60 on: September 05, 2017, 03:57:14 am »
I actually have a board exactly like yours - that is a very lucky coincidence.. So now I am looking at the display I have and I think it also should be adaptable.. but to make sure I am not making some kind of mistake, I'm going to post two photos I've taken of it.

Total newbie to using any kind of bitmapped display here.

This displays cost, like yours, around $2-3

I think I bought it based on the argument that it was so cheap, I knew it would come in use, and even if it took me some time to use, I would use it.

That was around two weeks ago. I guess there is a first time for everything.



"What the large print giveth, the small print taketh away."
 

Offline pigrew

  • Frequent Contributor
  • **
  • Posts: 680
  • Country: us
Re: ($40 GPSDO working well now, my mistake)
« Reply #61 on: September 05, 2017, 05:00:08 am »
I actually have a board exactly like yours - that is a very lucky coincidence.. So now I am looking at the display I have and I think it also should be adaptable.. but to make sure I am not making some kind of mistake, I'm going to post two photos I've taken of it.

I think that my code, as is, would work with any SSD1306-based 128x64 OLED with the internal DC-DC converter. Some boards will have a big inductor on the them for a DC-DC, and the display initialization routine would need to be changed to use that external voltage source.

I'd rather use a SPI3 interface, but I bought the I2C version. SPI3 would be faster.

Perhaps I should order the SPI3 version, and change my code to use it....
 

Offline cdevTopic starter

  • Super Contributor
  • ***
  • !
  • Posts: 7350
  • Country: 00
Re: ($40 GPSDO working well now, my mistake)
« Reply #62 on: September 05, 2017, 07:09:02 am »
I was looking at the libraries for it, its a bit faster and perhaps better for drawing graphs
"What the large print giveth, the small print taketh away."
 

Offline medical-nerd

  • Regular Contributor
  • *
  • Posts: 199
  • Country: gb
  • What's that coming over the hill?
Re: ($40 GPSDO working well now, my mistake)
« Reply #63 on: September 05, 2017, 11:09:56 am »
Hiya

I've been doing a search and looking on the packratvhf site - where do you get these particular GPSDO beasties?

I've already got a FRS-C rubidium, a FEI custom rubidium and a couple of Z3801a's and want to play some more!!  ;D

Cheers
'better to burn out than fade away'
 

Offline CJay

  • Super Contributor
  • ***
  • Posts: 4136
  • Country: gb
Re: ($40 GPSDO working well now, my mistake)
« Reply #64 on: September 05, 2017, 11:22:06 am »
Got mine from Fluke.I on eBay, untested $40 but it works, as far as I can see, perfectly after a few minor hiccups (one of which was me misplacing a decimal point and misunderstanding the $STATUS sentence, thought it was a bit odd that I was in the middle of the Atlantic)
 

Offline pigrew

  • Frequent Contributor
  • **
  • Posts: 680
  • Country: us
Re: ($40 GPSDO working well now, my mistake)
« Reply #65 on: September 05, 2017, 03:09:29 pm »
I've stared trying implement a microcontroller-control program.

The program is more complete now. Bi-directional USB seems to work. Still no button-inputs. Perhaps there is little need for button input (except maybe a display on/off feature?)

I posted some photos of the hardware reconfigurations of the microcontroller, if you'd like to play along.
« Last Edit: September 05, 2017, 04:15:58 pm by pigrew »
 

Offline cdevTopic starter

  • Super Contributor
  • ***
  • !
  • Posts: 7350
  • Country: 00
Re: ($40 GPSDO working well now, my mistake)
« Reply #66 on: September 05, 2017, 07:26:13 pm »
So, I am about to try to see if I can get it running on my breadboard in as simple a way as possible (just to verify its operating)first without the TruePosition online, to verify the display works, and then with the GPSDO.

I've changed the pull-ups. Here is my problem, I didn't have any SMD resistors that were both appropriate values and small enough. The ones I have are probably two sizes too large so I couldn't use them. So, what I did is I moved the 4.7k resistor on R3 down to R4, and bridged r8 with a 1k (approximately) smd resistor I had which was too big but it's bridging them, and it will hopefully stay there. Both sides look solidly soldered.

Dealing with these small SMD parts without the proper tools (working on that now) is a lot harder than dealing with larger ones for me.

Hopefully 1k on R8 wont be too small.

In the image it shows which resistors need to get changed.

What do you think? My SMD resistor situation is not so great. I thought that I had more somewhere. I think I do, actually, a little ziplock bag with assorted SMD parts from a store that sells them in little random packages, goldmine electronics.

Unless I can find that bag my only alternative to this that I can think of is attempting to remove resistors from junk boards.
"What the large print giveth, the small print taketh away."
 

Offline pigrew

  • Frequent Contributor
  • **
  • Posts: 680
  • Country: us
Re: ($40 GPSDO working well now, my mistake)
« Reply #67 on: September 05, 2017, 07:30:19 pm »
New command: $TRAINOXCO

It'll restart the unit ($PROCEED needed), wait a little bit for things to warm up, and then do OXCO training. During training, status is 7.

It measures the oscillator frequency at two points separated by 500 ADC counts.

Once it's done, status will go 9,10,11,12,13,0,19,20,21,22,1,0.

Edit: It's also good to note that the DAC voltage changes every second when status=1. It changes only every five seconds when status=0.
« Last Edit: September 05, 2017, 07:39:31 pm by pigrew »
 
The following users thanked this post: cdev

Offline pigrew

  • Frequent Contributor
  • **
  • Posts: 680
  • Country: us
Re: ($40 GPSDO working well now, my mistake)
« Reply #68 on: September 07, 2017, 12:47:38 am »
Hiya

I've been doing a search and looking on the packratvhf site - where do you get these particular GPSDO beasties?

I've already got a FRS-C rubidium, a FEI custom rubidium and a couple of Z3801a's and want to play some more!!  ;D

Cheers

How I wish I had a Z3801a... I'd imagine they are better than this board?

I got mine for about 120 RMB on Taobao. The seller says that he only guarantees the OCXO works, not the entire GPSDO. I should have bought a few more from him.

There's also another seller in the PRC on eBay (or maybe the same person?) who sells them for a bit more, but says  that the GPSDO will work.

I bought three boards (one had been crushed a bit), all different vintages. I'm not sure if the Bliley or the CTS crystal is better. The revisions of the GPS chipset are also different in different boards.

In terms of setting up boards, you should do a survey first ($SURVEY #), and write down the location where it says you are. I _think_ that it stores it in EEPROM automatically. You can set your location later with the $SETLOC command. Finally after it's warmed up for a while (>1 hour in an enclosure like a cardboard box), you should run $TRAINOCXO.

I have some personal software that I've written to make plots of the GPSDO status (windows-only, not published). I've also been working on a STM32-based controller which will automatically start up the board, and display status info on an OLED screen.
 

Offline texaspyro

  • Super Contributor
  • ***
  • Posts: 1407
Re: ($40 GPSDO working well now, my mistake)
« Reply #69 on: September 07, 2017, 12:55:13 am »
Where did you find the $TRAINOCXO command?  I did not see in my strings dump.
 

Offline cdevTopic starter

  • Super Contributor
  • ***
  • !
  • Posts: 7350
  • Country: 00
Re: ($40 GPSDO working well now, my mistake)
« Reply #70 on: September 07, 2017, 02:20:04 am »


Indeed.. Entering $TRAINOCXO kicked it back into Boot mode.. so now its training the OCXO?

(trying to figure out what's different)
« Last Edit: September 07, 2017, 02:25:42 am by cdev »
"What the large print giveth, the small print taketh away."
 

Offline pigrew

  • Frequent Contributor
  • **
  • Posts: 680
  • Country: us
Re: ($40 GPSDO working well now, my mistake)
« Reply #71 on: September 07, 2017, 02:32:26 am »
My GPSDO doesnt like $TRAINOCXO, at least not right now (its just gotten its GPS lock after 3 hours of trying to with my antenna indoors again.)

Entering $TRAINOCXO kicked it back into Boot mode..

That's what mine does, too. Look carefully at my post from yesterday. After it boots, it'll measure the frequency at two DAC values (separated by 500). Things seem slightly more stable after running the training (though I just noticed that it went into holdover for a moment).

I need to check if that sets the $GETSCALEFACTOR.... I'm not sure what scale factor it is.

Where did you find the $TRAINOCXO command?  I did not see in my strings dump.

I was trying random permutations of gain, train, tune, traim, and ocxo. I knew there must be some command like that, based on the packrat PPT (it lists a training mode).  (I don't know what $TRAIM does). It was scary when I saw it reboot the first time, but it seems to be normal.

I think that the software must use a complicated tree of if statements to decode the commands, so I think that they are not listed in the strings.

We'd need to decompile the binary in order to get the command list, I think. The strings only show the output of the unit, not the input.
 

Offline texaspyro

  • Super Contributor
  • ***
  • Posts: 1407
Re: ($40 GPSDO working well now, my mistake)
« Reply #72 on: September 07, 2017, 02:55:28 am »
Actually the strings do show the input commands (see things like $GETPOS. $GETA, $GETP, $SETPOS, etc).

TRAIM is time receiver autonomous integrity monitoring.   TRAIM modes basically check that the satellite data is consistent between all the sats and rejects sats that don't agree with the majority.
 

Offline texaspyro

  • Super Contributor
  • ***
  • Posts: 1407
Re: ($40 GPSDO working well now, my mistake)
« Reply #73 on: September 07, 2017, 02:58:10 am »
SCALEFACTOR probably maps the desired frequency control word to the EFC DAC setting... basically the "P" term in a PID controller.
 

Offline pigrew

  • Frequent Contributor
  • **
  • Posts: 680
  • Country: us
Re: ($40 GPSDO working well now, my mistake)
« Reply #74 on: September 07, 2017, 03:10:50 am »
Actually the strings do show the input commands (see things like $GETPOS. $GETA, $GETP, $SETPOS, etc).

The ones you mentioned are also all part of the responses that it sends. I was thinking that only responses are sent (but it usually responds with the same command ID as it was sent). The string list is also missing all of the responses/commands that I expected that it would be sending the GPS module.

TRAIM is time receiver autonomous integrity monitoring.   TRAIM modes basically check that the satellite data is consistent between all the sats and rejects sats that don't agree with the majority.

So, maybe it reports a $TRAIM message when it detects inconsistent satellites? I saw $TRAIM in the string listing, but I've never seen that message.


 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf