- Posts: 77
- Thank you received: 1
SSI ABS Encoder
andypugh wrote: counts-per-rev should probably be 4096. But that isn't the problem.
Setting it to a much larger number might be an interesting experiment, though.
Is there any way to see the raw data from the encoder? if no-wrap is active then the driver doesn't do very much with the data that comes back. Is it possible that what you see is the actual numbers from the encoder?
I think you can use "enable_raw" in the loadrt hostmot2 line of the hal and peek at the actual register values on the FPGA.
linuxcnc.org/docs/2.8/html/man/man9/hostmot2.9.html#Raw%20Mode
I have attached the hostmot2 register map so that you know where to look.
i have used an oscilloscope to see data. it returns a correct value from 0->4095
Please Log in or Create an account to join the conversation.
inverted clock maybe?
Andys raw read suggestion is good
For debugging, its important to see what the FPGA reads
Please Log in or Create an account to join the conversation.
andypugh wrote: Specifically this bit..
Code:SSI Data Register0, right justifed. Writes to this location will start a read cycle for the specific SSI interface addressed 0x6900 SSI data register0 channel 0 0x6904 SSI data register0 channel 1 0x6908 SSI data register0 channel 2 0x690C SSI data register0 channel 3 ... 0x6A00 SSI data register1 channel 0 0x6A04 SSI data register1 channel 1 0x6A08 SSI data register1 channel 2 0x6A0C SSI data register1 channel 3
Is it correct?
The values return from 0x0000000->0x0000ffff for 0->4096
thank you for your helping
Please Log in or Create an account to join the conversation.
show?
Please Log in or Create an account to join the conversation.
PCW wrote: What does hm2_7i80.0.ssi.00.zencoder.rawcounts
show?
it shows from 0-4096
But when I restart linux cnc, the values (3072 to 4096 ) is negative numbers from -1024 ->-1
Please Log in or Create an account to join the conversation.
annhandt09 wrote: The values return from 0x0000000->0x0000ffff for 0->4096
This is starting to look like it's my fault, then.
However I am fairly sure that the encoder wrapping logic works properly, as it is used extensively by things like the smart-serial MPG counters.
Is the returned position continuous at least? If it is then the conventional axis home offsets will mask the issue.
Please Log in or Create an account to join the conversation.