Request custom bitfile: 5i25 + 7i77 (P3) + 7i74 (P2) with pktUART for Modbus

More
4 months 3 days ago - 4 months 3 days ago #347402 by PCW
Yes, too old to run MODBUS which requires a PktUART version >1:


hm2/hm2_5i25.0: inconsistent Module Descriptor for PktUART Transmit Channel, not loading driver
hm2/hm2_5i25.0: Version = 3, expected 0



Also with this firmware there is no sserial port 1
(all channels = 0..7 are port 0)
Last edit: 4 months 3 days ago by PCW.

Please Log in or Create an account to join the conversation.

More
4 months 3 days ago #347405 by umerov
After updating LinuxCNC, it starts normally. I load it using:
loadrt hm2_pci config="num_encoders=3 num_pwmgens=0 num_stepgens=0 sserial_port_0=000000 num_pktuarts=2"

However, I have another problem: I can’t find any pins like these:
hm2_5i25.0.pktuart.0.tx-data
hm2_5i25.0.pktuart.0.tx-bytes
hm2_5i25.0.pktuart.0.rx-data
hm2_5i25.0.pktuart.0.rx-bytes

Please Log in or Create an account to join the conversation.

More
4 months 3 days ago - 4 months 3 days ago #347406 by PCW
The pktuart driver creates no hal pins

for modbus, you would use hm2_modbus:

man hm2_modbus

and mesambccc:

man mesambccc


 
Last edit: 4 months 3 days ago by PCW.

Please Log in or Create an account to join the conversation.

More
4 months 3 days ago #347407 by umerov
I understand how to use Modbus, thanks.
How do I use Channel 6: pktUART (RS-422 for the pendant)? Is it the same as Modbus?

Please Log in or Create an account to join the conversation.

More
4 months 3 days ago #347409 by PCW
What protocol does the pendant use?

Please Log in or Create an account to join the conversation.

More
4 months 2 days ago #347413 by umerov
The remote uses the RS422 protocol with a baud rate of 57600, configured for 8 data bits, no parity, and 1 stop bit (8N1).

For testing, I wrote a Python module to communicate with the remote via a COM-to-RS422 adapter, though I suspect it’s not very reliable.

My idea is to create a custom real-time LinuxCNC component, similar to the mesa_modbus component, and possibly use the internal hostmot2 C-API functions (hm2_pktuart_send(), hm2_pktuart_read(), and hm2_pktuart_setup()) to directly push and pull byte arrays into the FPGA’s transmit and receive FIFOs during the real-time servo thread.


 

Please Log in or Create an account to join the conversation.

Moderators: PCW, jmelson
Time to create page: 0.224 seconds
Powered by Kunena Forum