I am working on Lx2160 board to get IEEE 1588 1PPS.(on PULSE_OUT1 or PULSE_OUT2)
The flex-builer version that I used is 20.04.
It seems the kernel supports 1588 feature and I use linuxptp to test it.
However I couldn't find any document or instructions to enable 1PPS signal.
Please help. Thanks!
Please refer to "• Verify PPS signal " in LSDKUG_Rev20.04.pdf.
For generating 10 MHz and 1 PPS on the 1588, fiper registers have to be programmed accordingly. 1588_pulse_out1 and 1588_pulse_out2 pins is used for outputting 10MHz and 1pps.
We are using the LX2160ardb (rev2) reference board.
We change to CFG_MUX_EC2 = b'1, IEEECLK=b'0 in BRDCFG4 (0x54h) register of CPLD.
we have set up as below:
root@localhost:~# i2c-tools/i2cget -y 0 0x66 0x54
0x20
root@localhost:~# i2c-tools/i2cset -y 0 0x66 0x54 0xA0
root@localhost:~# i2c-tools/i2cget -y 0 0x66 0x54
0xa0
And, we modified the RCW file as follows :
diff rcw_2000_700_2900_19_5_2.rcw.origin rcw_2000_700_2900_19_5_2.rcw
29a30
> EC2_PMUX=2
flex-builder -c atf -m lx2160ardb_rev2 -b xspi
flex-builder -i mkfw -m lx2160ardb_rev2 -b xspi
And, we executed the following command in the kernel :
echo 1 > /sys/class/ptp/ptp0/pps_enable
cat /sys/class/pps/pps0/assert
root@localhost:~# cat /sys/class/pps/pps0/assert
1651636872.926440409#20
root@localhost:~# cat /sys/class/pps/pps0/assert
1651636874.926441180#22
But, We can't see pulse out
Q1 : Is there anything more we need to do?
If you have a working patch code, please send it to us.
Q2 : Does detailed documentation exist?
In RCW configuration, you should configure EC2_PMUX=1.
EC2_PMUX Configuration Configures the functionality of the EC2 pins
0b00 - WRIOP MAC 18 RGMII
0b01 - IEEE1588 and GPIO4 for the remaining
0b10 - GPIO4
0b11 - Reserved
[Note] We referred page 179 of the LX2160ARM.pdf (Rev. 1, 10/2021)
If a new LX2160ARM.pdf file exists, please let us know.
Thanks,
Thanks,
I had tried on Lx2160_ARDB Rev2 reference board. but cannot get any signal.
after configured "echo 1 > /sys/class/ptp/ptp1/pps_enable" /sys/class/pps/pps0/assert was increased.
But not shown any signal on 1588_PULSE_OUT1 and 1588_PULSE_OUT2.
is there any preparation ?
Thanks.