Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
| enable_pps_support_raspian [2019/11/03 09:20] – [Step 1: Download kernel] nikolal | enable_pps_support_raspian [2022/09/19 11:34] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 3: | Line 3: | ||
| * CONFIG_PPS ("PPS support" | * CONFIG_PPS ("PPS support" | ||
| * CONFIG_NTP_PPS ("PPS kernel consumer support" | * CONFIG_NTP_PPS ("PPS kernel consumer support" | ||
| - | ===== Step 1: Download kernel | + | ==== Install dependencies ==== |
| + | '' | ||
| + | ==== Download kernel ==== | ||
| mkdir ppskernel | mkdir ppskernel | ||
| cd ppskernel | cd ppskernel | ||
| Line 11: | Line 13: | ||
| zcat / | zcat / | ||
| make oldconfig | make oldconfig | ||
| + | |||
| + | ==== Configure kernel build options ==== | ||
| + | |||
| Then comes the hard part, setting the options. Normally this is straight forward, but due to some options only showing when others are disabled, it may be a little tricky. | Then comes the hard part, setting the options. Normally this is straight forward, but due to some options only showing when others are disabled, it may be a little tricky. | ||
| - | make menuconfig | + | |
| - | Go to '' | + | * Go to '' |
| - | ==== Turn on PPS support: | + | |
| - | Device Drivers ---> | + | * Enter Device Drivers ---> PPS support ---> |
| - | | + | \\ |
| <M> PPS support | <M> PPS support | ||
| [ ] PPS debugging messages | [ ] PPS debugging messages | ||
| Line 23: | Line 28: | ||
| *** PPS clients support *** | *** PPS clients support *** | ||
| < > Kernel timer client (Testing client, use for debug) | < > Kernel timer client (Testing client, use for debug) | ||
| - | < > PPS line discipline | + | <M> PPS line discipline |
| < | < | ||
| *** PPS generators support *** | *** PPS generators support *** | ||
| + | \\ | ||
| + | * Save and exit. To verify, check the '' | ||
| + | \\ | ||
| + | CONFIG_PPS=y | ||
| + | CONFIG_NTP_PPS=y | ||
| + | # | ||
| + | # Timers subsystem | ||
| + | # | ||
| + | CONFIG_TICK_ONESHOT=y | ||
| + | CONFIG_HZ_PERIODIC=y | ||
| + | # CONFIG_NO_HZ_IDLE is not set | ||
| + | # CONFIG_NO_HZ_FULL is not set | ||
| + | # CONFIG_NO_HZ is not set | ||
| + | CONFIG_HIGH_RES_TIMERS=y | ||
| + | # CONFIG_PREEMPT_NONE is not set | ||
| + | CONFIG_PREEMPT_VOLUNTARY=y | ||
| + | # CONFIG_PREEMPT is not set | ||
| + | ==== Compile the kernel ==== | ||
| + | make -j4 | ||
| + | make modules | ||
| + | \\ | ||
| + | * Gain superuser privileges and transfer a copy of the new kernel to the boot partition: | ||
| + | \\ | ||
| + | sudo -i | ||
| + | cd ~pi/ | ||
| + | make modules_install | ||
| + | cp ./ | ||
| + | \\ | ||
| + | * Tell the system to use this new kernel by adding '' | ||
| + | * Reboot | ||
| + | ==== Add PPS source and load kernel module ==== | ||
| + | * Open '' | ||
| + | * Load kernel module: '' | ||
| + | ==== Test and make permanent==== | ||
| + | * Test | ||
| + | \\ | ||
| + | apt-get install pps-tools | ||
| + | sudo ppstest /dev/pps0 | ||
| + | \\ | ||
| + | * Expected result is something like: | ||
| + | \\ | ||
| + | trying PPS source "/ | ||
| + | found PPS source "/ | ||
| + | ok, found 1 source(s), now start fetching data... | ||
| + | source 0 - assert 1572772437.999997402, | ||
| + | source 0 - assert 1572772438.999997803, | ||
| + | source 0 - assert 1572772440.000000924, | ||
| + | source 0 - assert 1572772440.999998834, | ||
| + | source 0 - assert 1572772442.000001424, | ||
| + | source 0 - assert 1572772442.999999478, | ||
| + | source 0 - assert 1572772444.000000128, | ||
| + | source 0 - assert 1572772444.999999537, | ||
| + | source 0 - assert 1572772446.000000578, | ||
| + | |||
| + | |||
| + | \\ | ||
| + | * If successful, make permanent by opening '' | ||
| + | * Running a DUNE configuration with '' | ||
| ===== Links ===== | ===== Links ===== | ||
| * [[https:// | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[http:// | ||
| + | * [[https:// | ||