New project, litehm2: a hostmot2 port to linsn rv901t

More
01 Jul 2023 05:55 - 01 Jul 2023 07:08 #274556 by sensille
I built the bitstream, it is in the attachment. I only tested that mesaflash --readhmid still works with it, so please test carefully. It you want a different pinout or other function, please edit the attached conf file and send it to me, so I can compile a new bitstream for you. 
 

File Attachment:

File Name: rv901t_for...conf.txt
File Size:6 KB
  

File Attachment:

File Name: rv901t_for_xu.bit.txt
File Size:454 KB
Attachments:
Last edit: 01 Jul 2023 07:08 by sensille.

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

More
01 Jul 2023 10:08 #274573 by xu
Thank sensille
The bit firmware can work normally, and the tool for modifying the circuit board is still on the way, so no further testing is possible

cnc@debian:~/linuxcnc/configs/litehm2_6040$ halrun -I -V HAL.hal
HAL: initializing hal_lib
HAL: initializing component 'halcmd2749'
smalloc_dn: shmem available 1048184
HAL: component 'halcmd2749' initialized, ID = 02
HAL: removing component 02
HAL: releasing RTAPI resources
HAL: component 02 removed, name = 'halcmd2749'
HAL: initializing hal_lib
/usr/bin/rtapi_app load hostmot2
HAL: initializing component 'halcmd2749'
smalloc_dn: shmem available 1048184
HAL: component 'halcmd2749' initialized, ID = 02
Note: Using POSIX realtime
hm2: loading Mesa HostMot2 driver version 0.15
HAL.hal:2: Component 'hostmot2' ready
HAL.hal:2: Program '/usr/bin/rtapi_app' started
smalloc_up: shmem available 1048071
HAL.hal:2: Realtime module 'hostmot2' loaded
HAL: removing component 02
HAL: releasing RTAPI resources
HAL: component 02 removed, name = 'halcmd2749'
HAL: initializing hal_lib
/usr/bin/rtapi_app load hm2_eth board_ip="10.10.10.10" config=" num_encoders=6 num_pwmgens=2 num_stepgens=6 sserial_port_0=0000xx"
HAL: initializing component 'halcmd2749'
HAL: component 'halcmd2749' initialized, ID = 06
hm2_eth: loading Mesa AnyIO HostMot2 ethernet driver version 0.2
hm2_eth: 10.10.10.10: INFO: Hardware address (MAC): 24:1f:83:30:66:de
hm2_eth: Unrecognized ethernet board found: litehm2 -- port names will be wrong
hm2_eth: discovered litehm2
hm2/hm2_lite.0: Low Level init 0.15
hm2/hm2_lite.0: 72 I/O Pins used:
hm2/hm2_lite.0: IO Pin 000 (??-01): IOPort
hm2/hm2_lite.0: IO Pin 001 (??-03): IOPort
hm2/hm2_lite.0: IO Pin 002 (??-05): IOPort
hm2/hm2_lite.0: IO Pin 003 (??-07): IOPort
hm2/hm2_lite.0: IO Pin 004 (??-09): IOPort
hm2/hm2_lite.0: IO Pin 005 (??-11): IOPort
hm2/hm2_lite.0: IO Pin 006 (??-13): IOPort
hm2/hm2_lite.0: IO Pin 007 (??-15): IOPort
hm2/hm2_lite.0: IO Pin 008 (??-17): IOPort
hm2/hm2_lite.0: IO Pin 009 (??-19): IOPort
hm2/hm2_lite.0: IO Pin 010 (??-21): IOPort
hm2/hm2_lite.0: IO Pin 011 (??-23): IOPort
hm2/hm2_lite.0: IO Pin 012 (??-25): IOPort
hm2/hm2_lite.0: IO Pin 013 (??-27): IOPort
hm2/hm2_lite.0: IO Pin 014 (??-29): IOPort
hm2/hm2_lite.0: IO Pin 015 (??-31): IOPort
hm2/hm2_lite.0: IO Pin 016 (??-33): IOPort
hm2/hm2_lite.0: IO Pin 017 (??-35): IOPort
hm2/hm2_lite.0: IO Pin 018 (??-37): IOPort
hm2/hm2_lite.0: IO Pin 019 (??-39): IOPort
hm2/hm2_lite.0: IO Pin 020 (??-41): IOPort
hm2/hm2_lite.0: IO Pin 021 (??-43): IOPort
hm2/hm2_lite.0: IO Pin 022 (??-45): IOPort
hm2/hm2_lite.0: IO Pin 023 (??-47): IOPort
hm2/hm2_lite.0: IO Pin 024 (??-01): IOPort
hm2/hm2_lite.0: IO Pin 025 (??-03): IOPort
hm2/hm2_lite.0: IO Pin 026 (??-05): StepGen #0, pin Step (Output)
hm2/hm2_lite.0: IO Pin 027 (??-07): StepGen #0, pin Step (Output)
hm2/hm2_lite.0: IO Pin 028 (??-09): StepGen #0, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 029 (??-11): StepGen #0, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 030 (??-13): StepGen #1, pin Step (Output)
hm2/hm2_lite.0: IO Pin 031 (??-15): StepGen #1, pin Step (Output)
hm2/hm2_lite.0: IO Pin 032 (??-17): StepGen #1, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 033 (??-19): StepGen #1, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 034 (??-21): StepGen #2, pin Step (Output)
hm2/hm2_lite.0: IO Pin 035 (??-23): StepGen #2, pin Step (Output)
hm2/hm2_lite.0: IO Pin 036 (??-25): StepGen #2, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 037 (??-27): StepGen #2, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 038 (??-29): StepGen #3, pin Step (Output)
hm2/hm2_lite.0: IO Pin 039 (??-31): StepGen #3, pin Step (Output)
hm2/hm2_lite.0: IO Pin 040 (??-33): StepGen #3, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 041 (??-35): StepGen #3, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 042 (??-37): StepGen #4, pin Step (Output)
hm2/hm2_lite.0: IO Pin 043 (??-39): StepGen #4, pin Step (Output)
hm2/hm2_lite.0: IO Pin 044 (??-41): StepGen #4, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 045 (??-43): StepGen #4, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 046 (??-45): StepGen #5, pin Step (Output)
hm2/hm2_lite.0: IO Pin 047 (??-47): StepGen #5, pin Step (Output)
hm2/hm2_lite.0: IO Pin 048 (??-01): StepGen #5, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 049 (??-03): StepGen #5, pin Direction (Output)
hm2/hm2_lite.0: IO Pin 050 (??-05): PWMGen #0, pin Out0 (PWM or Up) (Output)
hm2/hm2_lite.0: IO Pin 051 (??-07): PWMGen #0, pin Out1 (Dir or Down) (Output)
hm2/hm2_lite.0: IO Pin 052 (??-09): PWMGen #1, pin Out0 (PWM or Up) (Output)
hm2/hm2_lite.0: IO Pin 053 (??-11): PWMGen #1, pin Out1 (Dir or Down) (Output)
hm2/hm2_lite.0: IO Pin 054 (??-13): Encoder #0, pin A (Input)
hm2/hm2_lite.0: IO Pin 055 (??-15): Encoder #0, pin B (Input)
hm2/hm2_lite.0: IO Pin 056 (??-17): Encoder #0, pin Index (Input)
hm2/hm2_lite.0: IO Pin 057 (??-19): Encoder #1, pin A (Input)
hm2/hm2_lite.0: IO Pin 058 (??-21): Encoder #1, pin B (Input)
hm2/hm2_lite.0: IO Pin 059 (??-23): Encoder #1, pin Index (Input)
hm2/hm2_lite.0: IO Pin 060 (??-25): Encoder #2, pin A (Input)
hm2/hm2_lite.0: IO Pin 061 (??-27): Encoder #2, pin B (Input)
hm2/hm2_lite.0: IO Pin 062 (??-29): Encoder #2, pin Index (Input)
hm2/hm2_lite.0: IO Pin 063 (??-31): Encoder #3, pin A (Input)
hm2/hm2_lite.0: IO Pin 064 (??-33): Encoder #3, pin B (Input)
hm2/hm2_lite.0: IO Pin 065 (??-35): Encoder #3, pin Index (Input)
hm2/hm2_lite.0: IO Pin 066 (??-37): Encoder #4, pin A (Input)
hm2/hm2_lite.0: IO Pin 067 (??-39): Encoder #4, pin B (Input)
hm2/hm2_lite.0: IO Pin 068 (??-41): Encoder #4, pin Index (Input)
hm2/hm2_lite.0: IO Pin 069 (??-43): Encoder #5, pin A (Input)
hm2/hm2_lite.0: IO Pin 070 (??-45): Encoder #5, pin B (Input)
hm2/hm2_lite.0: IO Pin 071 (??-47): Encoder #5, pin Index (Input)
hm2/hm2_lite.0: registered
HAL.hal:3: Component 'hm2_eth' ready
HAL.hal:3: Program '/usr/bin/rtapi_app' started
smalloc_up: shmem available 971164
HAL.hal:3: Realtime module 'hm2_eth' loaded
HAL.hal:4: setting parameter 'hm2_lite.0.watchdog.timeout_ns' to '5000000'
HAL.hal:4: Parameter 'hm2_lite.0.watchdog.timeout_ns' set to 5000000
HAL: removing component 06
HAL: releasing RTAPI resources
HAL: component 06 removed, name = 'halcmd2749'
HAL: initializing hal_lib
/usr/bin/rtapi_app load pid names=pid.x,pid.y,pid.z,pid.s
HAL: initializing component 'halcmd2749'
HAL: component 'halcmd2749' initialized, ID = 09
HAL.hal:5: Component 'pid' ready
HAL.hal:5: Program '/usr/bin/rtapi_app' started
smalloc_up: shmem available 952673
HAL.hal:5: Realtime module 'pid' loaded
HAL: removing component 09
HAL: releasing RTAPI resources
HAL: component 09 removed, name = 'halcmd2749'
HAL: initializing hal_lib
/usr/bin/rtapi_app load mux4
HAL: initializing component 'halcmd2749'
HAL: component 'halcmd2749' initialized, ID = 12
HAL.hal:6: Component 'mux4' ready
HAL.hal:6: Program '/usr/bin/rtapi_app' started
smalloc_up: shmem available 951295
HAL.hal:6: Realtime module 'mux4' loaded
HAL: removing component 12
HAL: releasing RTAPI resources
HAL: component 12 removed, name = 'halcmd2749'
HAL: initializing hal_lib
/usr/bin/rtapi_app load mult2
HAL: initializing component 'halcmd2749'
HAL: component 'halcmd2749' initialized, ID = 15
HAL.hal:7: Component 'mult2' ready
HAL.hal:7: Program '/usr/bin/rtapi_app' started
smalloc_up: shmem available 950383
HAL.hal:7: Realtime module 'mult2' loaded
HAL: removing component 15
HAL: releasing RTAPI resources
HAL: component 15 removed, name = 'halcmd2749'
HAL: initializing hal_lib
HAL: initializing component 'halcmd2749'
HAL: component 'halcmd2749' initialized, ID = 18
/usr/bin/rtapi_app load estop_latch
HAL.hal:8: Component 'estop_latch' ready
HAL.hal:8: Program '/usr/bin/rtapi_app' started
smalloc_up: shmem available 949099
HAL.hal:8: Realtime module 'estop_latch' loaded
HAL: removing component 18
HAL: releasing RTAPI resources
HAL: component 18 removed, name = 'halcmd2749'
HAL: initializing hal_lib
/usr/bin/rtapi_app load or2 count=3
HAL: initializing component 'halcmd2749'
HAL: component 'halcmd2749' initialized, ID = 21
HAL.hal:9: Component 'or2' ready
HAL.hal:9: Program '/usr/bin/rtapi_app' started
smalloc_up: shmem available 946615
HAL.hal:9: Realtime module 'or2' loaded
HAL: adding function 'hm2_lite.0.read' to thread 'servo-thread'
HAL: ERROR: thread 'servo-thread' not found
HAL.hal:11: addf failed
HAL: removing component 21
HAL: releasing RTAPI resources
HAL: component 21 removed, name = 'halcmd2749'

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

More
02 Jul 2023 03:48 #274618 by xu
   Dear Sensille
  I think I may not use the encoder index, so that there are a few more inputs, can you help me rebuild the bit file?
Attachments:

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

More
02 Jul 2023 06:27 #274625 by sensille
New bitstream is attached, but it wouldn't have been strictly necessary. The encoder is just the secondary function. You can also just use any encoder input as ordinary input. The same holds for output, you can use the stepgen outputs you don't need as ordinary outputs as well.
 

File Attachment:

File Name: rv901t__fo....bit.txt
File Size:454 KB
Attachments:

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

More
02 Jul 2023 07:13 #274626 by besriworld
Can you link to aliexpress for the correct board? I have 5A75E but it seems the project has stopped development. This project seems to work well.

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

More
02 Jul 2023 07:21 #274627 by sensille
rv901t is the correct designation. Bonus if you can read "spartan" on the FPGA chip in the product picture.
I'm also working on making this project available for 5a75 (lattice ecp5), but I can't say how long it will take.
The following user(s) said Thank You: besriworld

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

More
02 Jul 2023 09:28 #274628 by besriworld
This is very good news! Thanks !

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

More
02 Jul 2023 12:31 #274635 by xu
Dear sensille
Your bit file is # J601, 40 pins
# Buffered through U603: 7-14 out
# Buffered through U607: 15-22 out
# Buffered through U602: 23-30 out
# Buffered through U606: 31-38 out
# Buffered through U608, shared with J600: 39-45 out
#
# J600, 32 pins
# Buffered through U600: 7-14 in
# Buffered through U604: 15-22 in
# Buffered through U601: 23-30 in
# Buffered through U605: 31-38 in

Ilya Kw wrote:
In case of RV901T you should cut one trace in two places then solder it to GND and add a smd 0805 1k resistor to 3V3. In the end you will get U603, U607, U602, U606 as input and U605, U601, U604, U600 as output ports.


The result of your transformation is the opposite, can you recreate the bitfile of the transformation method IlyaKw wrote?

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

More
02 Jul 2023 18:29 #274655 by sensille
Please check if the config suits your needs. The pin assignment is different.



 

File Attachment:

File Name: rv901t_ily....bit.txt
File Size:454 KB

File Attachment:

File Name: rv901t_ily...conf.txt
File Size:2 KB
Attachments:

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

More
02 Jul 2023 18:31 #274656 by sensille
I pushed some commits to master that add the modules inm, inmux and sserial. The latter two are untested.
The following user(s) said Thank You: besriworld

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

Moderators: PCWjmelson
Time to create page: 0.614 seconds
Powered by Kunena Forum