**** BEGIN LOGGING AT Tue Oct 01 02:59:57 2019 Oct 01 13:35:36 jkridner[m]: btw, I noticed that the 24 MHz crystal on beaglebones seems to consistently run a bit fast and outside the spec (+/-30ppm)... the four that are on the network here right now are +37 ppm, +46 ppm, +48 ppm, and +50 ppm (according to chrony), and I've measured similar values on other beaglebones in the past Oct 01 13:36:46 not a significant issue, but I think it's curious that they always seem to be a bit high, never a bit low Oct 01 13:43:36 two more beaglebones: +45.5 ppm, +48 ppm Oct 01 13:58:46 What is the temperature range of the Beaglebone AI? Oct 01 14:28:41 zmatt 2 questions 1 has the board changed and what was the average +std deviation on prior revisions 2 has the FW or SW for configuration of the timing system changed? It's possible that the crystal itself is the problem, but generally unlikely. that's all I can think Oct 01 14:40:16 GenTooMan: all of these are rev C... I have an A5A somewhere I could dust off to check, although 1 sample point wouldn't be very informative Oct 01 14:41:36 I suppose it could be the kernel, but that would be a really weird and serious bug Oct 01 14:41:46 I'm more inclined to blame the osc itself Oct 01 14:42:37 I don't know how sensitive the frequency is to the components around the crystal like the caps Oct 01 14:46:33 you can get change if the load changes on the crystal changes I assume they have loading caps on the crystal. Having experienced RF components et al even a simple cap change on seemingly unrelated stuff can be a problem. I agree though it's kind of strange. I assume the manufacturer loads the devices with some FW/SW to test the board and generates some record of conformance. Oct 01 14:47:29 is there reason to assume such a test has been done? I don't think the BBB itself has a direct spec on this Oct 01 14:48:15 the schematic has 18 pF caps to ground on both sides of the crystal, and 1M resistor in parallel to it Oct 01 14:49:03 the crystal seems to be this => https://www.digikey.com/product-detail/en/txc-corporation/7A-24.000MAAJ-T/887-1090-1-ND/2118967 Oct 01 14:53:03 hmm Oct 01 14:55:11 am335x datasheet says about those caps (C1 and C2) and they should be selected such that the load capacitance C_L = C1 * C2 / (C1 + C2) + Cshunt equals the value specified by the crystal... Cshunt is 5 pF (max), C1 and C2 are 18 pF, doing the math says C_L = 14 pF yet the crystal specs 18 pF Oct 01 14:55:28 *that they should... Oct 01 14:57:11 but the pcb layout will have some capacitance Oct 01 14:58:18 right Oct 01 14:58:25 *shrug* Oct 01 14:58:59 I'm just guessing shit... all I know is that they seem to consistently run fast Oct 01 14:59:52 that's why I asked about the board layout. Did they change the board material? That will affect capacitance also. the solder mask can too but 24MHz isn't likely to be affected by that. Oct 01 15:00:23 I have no idea about these things Oct 01 15:00:57 I'll see if I can get a measurement on my old A5A when I'm home... if it turns out to be spot on then that would be interesting Oct 01 15:01:11 one could guess for a 5+ year old design, the same pcb supplier hasn't benn used. ;) Oct 01 15:02:21 zmatt yes having a few points of reference is always good. I know when we had RF devices a few ppm was very bad. we had to be within 18ppm to maintain compliance at 915MHz. Oct 01 15:02:52 tbh 30ppm is such a loose spec, I wouldn't be using it for anything where the frequency mattered much. If it's twice as bad as spec and you care, you're using something that isn't appropriate Oct 01 15:03:45 artag: well the thing I noticed is that the spread between BBBs isn't much, but collectively they're significantly above the nominal value Oct 01 15:04:09 yeah, it's certainly interesting to see the spread. Just not critical. Oct 01 15:07:14 would also be intersting to compare with boards that are laid out and manufactured elsewhere, like the seeed ones Oct 01 15:07:47 the fact that they're close together yet all around +45..+50 ppm (except one that's +39 ppm, maybe because it's much better ventilated than the others) suggests maybe the nominal frequency is off for whatever reason Oct 01 15:08:09 truth if you don't need it don't worry. If you need precise timing you would be using an oscillator not a crystal. Oct 01 15:08:27 yeah it's not an actual problem, just an observation Oct 01 15:09:15 I noticed it because we're doing stuff with time sync between devices, so that causes one to end up looking at numbers like these :) Oct 01 15:11:10 I had to keep accurate time over a period of 10years without sync within 8 hours so ... I know how that feels. Oct 01 15:14:16 well I mean that allows for 90 ppm deviation :) Oct 01 15:15:46 Umm you say that so innocently, however doing the calculations yields some quite annoying numbers 158ppm deviation over 10 years from the initial value.. really. Oct 01 15:17:09 yeah I'm glad I don't need to make any long-term guarantees like that Oct 01 15:18:02 although precision time sync over a network (on residentual ethernet networks of unknown quality) has its own headaches Oct 01 15:18:10 *residential Oct 01 15:18:43 well the protocol accounts for network latency if I remember correctly. Oct 01 15:19:59 it measures round-trip delay but that doesn't tell you whether that delay occurred in one direction or the other Oct 01 15:20:12 plus you still need to filter that stuff Oct 01 15:20:51 we've also had cases where people had a switches that for some reason blocked PTP packets :( Oct 01 15:34:43 hmm actually I just realized that ventilation/temperature can't explain the one that's lower than the other (+37 ppm) ... I think it's significantly older than the others though Oct 01 15:41:17 *shrug* Oct 01 15:51:04 can't explain because it isn't any difference ? or because of the direction of change ? Sign of tempco isn't necessarily consistent, as ideally a crystal would be at the turnover pint (for lowest coefficient) Oct 01 15:51:15 *point Oct 01 15:52:55 I tried searching for what sort of temp curve a typical crystal has, the first two docs I found both showed a curve that had a maximum around -10 deg C and minimum just above +60 deg C Oct 01 15:53:34 with the nominal deviation at 25 deg C Oct 01 15:57:29 the difference between the +37 one and the +45..+50 ones may not be significant, that spread is well within spec Oct 01 16:38:42 I just measured a bbg using a non-contact rf probe and got 10ppm low. But I probably need to check the calibration on my analyser. Oct 01 16:39:27 23.99974MHz Oct 01 16:40:13 the 24 MHz circuit is totally different on the BBG Oct 01 16:40:29 it has a spread-spectrum oscillator Oct 01 16:42:05 it still has a 24MHz crystal though, so does it synthesize the ss ? I wouldn't expect it to pull the crystal Oct 01 16:42:37 ah you're measuring directly on the crystal? Oct 01 16:43:32 ummm directly on the crystal? Oct 01 16:43:58 yes Oct 01 16:44:10 with an e-field emc probe Oct 01 16:44:26 ahh... so you aren't directly touching it, that's better. Oct 01 16:44:57 that's right. though I got the same value with a high impedance probe Oct 01 16:45:02 touching a pin Oct 01 16:45:16 like, it has a SSC chip that oscillates the crystal and synthesizes a spread-spectrum clock from it (indeed it doesn't pull the osc) Oct 01 16:45:30 yeah, sounds likely Oct 01 16:45:33 anyway, it's a different circuit, different pcb, so not really a useful comparison Oct 01 16:46:04 i was avoiding the bbb as it has a cape on that was hard to remove. but it turns out the crystal is on the bottom so not so hard .. Oct 01 16:46:22 just run an ntp client :P Oct 01 16:46:23 i get 24.00106 from that Oct 01 16:46:32 meh, hardware is easier :) Oct 01 16:47:09 that's +44 ppm Oct 01 16:47:12 :) Oct 01 16:47:24 indeed ! Oct 01 16:47:31 Hmmm sounds about the same too me Oct 01 16:47:46 yep that's nicely in the range I've been seeing Oct 01 16:49:56 i've had this onme 3-4 years. is there a rev. number to look for ? Oct 01 16:50:21 if it has 4GB of eMMC then it's rev C Oct 01 16:51:04 yeah think so. it's badged element14 fwiw Oct 01 16:51:10 I have 3 rev B and 1 rev C but nothing to measure with at the moment. Oct 01 16:51:23 GenTooMan: ntp client Oct 01 16:51:34 it just takes a while Oct 01 16:58:32 GenTooMan: we run chrony and it creates a /var/lib/chrony/chrony.drift file containing the frequency deviation (in ppm) and its error bound estimate Oct 01 17:24:26 zmatt: I've tried adjusting your fbtft-adafruit18.dtsi to work with a 2.2 inch screen: https://github.com/desttinghim/overlay-utils/blob/master/fbtft-hiletgo22.dtsi but all I am getting is a flickering. The driver is an ili9341, but oddly enough the st7735 overlay seemed to work better than what I wrote. Oct 01 17:24:53 Actually, the flickering isn't happening any more Oct 01 17:25:02 But I am getting no output to it Oct 01 17:26:21 would that be the adafruit22a screen? Oct 01 17:26:46 never mind Oct 01 17:27:02 I believe it is one of the cheap clones Oct 01 17:27:22 at the very least the gamma should be removed, it was specific to that adafruit screen Oct 01 17:27:45 Ah, ok Oct 01 17:28:30 all predefined examples in fbtft_device.c have no gamma but bgr true (i.e. "bgr;" in DT) Oct 01 17:28:57 (all predefined examples for the ili9341 I mean) Oct 01 17:29:35 it may also be worth lowering the max frequency just in case there's signal issues Oct 01 17:31:23 Okay, I removed the gamma and uncommented the bgr line Oct 01 17:31:28 (and none of them specify fps) Oct 01 17:31:28 And it works! Oct 01 17:31:32 hah Oct 01 17:33:26 I wonder what this "gamma" actually is, since it really doesn't look much like a gamma curve to me Oct 01 17:34:26 or if it is one, it must have a pretty weird format Oct 01 17:36:23 I wouldn't know, but I'm guessing it has something to do with the driver chip Oct 01 17:36:55 https://cdn-shop.adafruit.com/datasheets/ILI9341.pdf .. check out pages 188 and 189 Oct 01 17:37:06 it claims to be gamma correction alright, and indeed the format is weird as fuck Oct 01 17:37:25 (and "positive" and "negative" gamma? o.O) Oct 01 17:38:15 The gamma was for the st7735 chip though, not the ili9341 Oct 01 17:38:28 Maybe the ili9341 does need it then? Oct 01 17:38:38 it has a default gamma in the driver Oct 01 17:38:58 which doesn't resemble the adafruit one for the st7735r Oct 01 17:40:38 so they're both really weird Oct 01 17:40:48 which has similar registers which has a totally different but equally weird format Oct 01 17:41:14 but yeah it seems to configure a bunch of voltages, probably not something you want to misconfigure Oct 01 17:42:40 http://cdn.shopify.com/s/files/1/0803/9211/files/ST7735R.pdf (pages 148 and 150) Oct 01 17:44:24 I'll just stick with the defaults. thanks for the help again! Oct 01 17:50:02 yeah, you can always fine-tune it later if you want to improve the quality Oct 01 23:31:23 zmatt: re the xtal running high... that can be tweaked by the loading caps...prehaps the strays on the PCB have changed since gerald did his magic Oct 01 23:46:02 dumb question does the oscillator have programmable loading caps built in? I know some of the less expensive TI parts have them. Oct 01 23:46:20 pretty sure it doesn't Oct 01 23:46:24 but too lazy to check :P Oct 02 00:43:47 no Oct 02 00:44:27 the loading cap is a function of the PC stray caps Oct 02 00:45:03 it is on the order of 10-20pF's so strays are significant Oct 02 00:50:39 I wonder why the bbb has an external 1Mohm resistor parallel to the crystal when the am335x already has one internally (enabled by default, can be disabled by software) Oct 02 01:05:18 if I understand correctly the frequency being too high implies there's insufficient capacitance... the math says there should be 2x 26 pF (incl stray capacitance), there are two 18 pF caps, the package adds negligible according to the datasheet (0.01 pF), so the pcb would need to contribute 2x 8 pF Oct 02 01:07:08 is the 1M populated? Oct 02 01:07:09 wait that's wrong Oct 02 01:07:13 good question Oct 02 01:07:35 IIRC - the parallel resistor is recommended by TI (had a discussion about this with the Octavo guys) Oct 02 01:09:55 the two caps are effectively in series... that's why there's (C1*C2)/(C1+C2) (i.e. 1/(1/C1 + 1/C2)) in that formula, but other than that I shouldn't formulate it as "2x" anything... it's just 18 pF total minus 5 from the crystal (max), 1/(1/18+1/18) = 9 from the caps, so that leaves 4 pF to be contributed by the pcb... eh, I guess I wasn't that wrong because that's 4 pF between the pins, or ... Oct 02 01:10:01 ...equivalently 8 pF to ground on each pin Oct 02 01:10:49 schematic seems to think it's populated Oct 02 01:11:06 yeah it's populated Oct 02 01:11:43 was it populated in the first rev? Oct 02 01:12:11 not even sure what the "first rev" is **** ENDING LOGGING AT Wed Oct 02 02:59:57 2019