Advanced Search

Search Results (Searched for: ncbox)

22 Jan 2024 19:04 - 22 Jan 2024 19:06

hostmot2 encoder documentation

Category: Driver Boards

Enabling quad error with machine-on signals won't work. I believe there is an error in the encoder implementation. It is detecting quadrature errors even when quad-error-enable is false. This bug was confusing because quad faults don't trigger until until you set quad-error-enable true. 

I setup a halrun_encoder_test.hal that illustrates this problem. This file will start up an encoder and display the quad-error, quad-error-enable, count.

Next use the input-a, input-b to cause a quad error. (I have a bad glass scale that I connect, but connecting a & b inputs together and toggling should also cause a quad error.)

This fault will be ignored (since quad-error-enable is FALSE). BUT when you "sets encoder-quad-enable TRUE", the error which should have been cleared triggers. This means you can not ignore spurious quad errors at startup. You will have to close the quad error dialog. Seems like this is a fpga bug? If there is a way to disable the quad error dialog I could toggle the enable before the machine starts.

Is there any way to:
  • Fix this bug(fpga?)
  • Disable the dialog (hostmot2)

    Should I open up an issue somewhere?


cncbox@debian:~/linuxcnc/configs/Mill7i85s$ halrun -I halrun_encoder_test.hal
halrun_encoder_test.hal:6: Warning: File contains DOS-style line endings.
Note: Using POSIX realtime
hm2: loading Mesa HostMot2 driver version 0.15
hm2_eth: loading Mesa AnyIO HostMot2 ethernet driver version 0.2
hm2_eth: 10.10.10.10: INFO: Hardware address (MAC): 00:60:1b:13:05:4e
hm2_eth: discovered 7I92
hm2/hm2_7i92.0: Low Level init 0.15
hm2/hm2_7i92.0: Smart Serial Firmware Version 43
hm2/hm2_7i92.0: 34 I/O Pins used:
hm2/hm2_7i92.0:     IO Pin 000 (P2-01): IOPort
hm2/hm2_7i92.0:     IO Pin 001 (P2-14): IOPort
hm2/hm2_7i92.0:     IO Pin 002 (P2-02): IOPort
hm2/hm2_7i92.0:     IO Pin 003 (P2-15): IOPort
hm2/hm2_7i92.0:     IO Pin 004 (P2-03): IOPort
hm2/hm2_7i92.0:     IO Pin 005 (P2-16): IOPort
hm2/hm2_7i92.0:     IO Pin 006 (P2-04): IOPort
hm2/hm2_7i92.0:     IO Pin 007 (P2-17): IOPort
hm2/hm2_7i92.0:     IO Pin 008 (P2-05): IOPort
hm2/hm2_7i92.0:     IO Pin 009 (P2-06): IOPort
hm2/hm2_7i92.0:     IO Pin 010 (P2-07): Muxed Encoder Select #0, pin Mux Select 0 (Output)
hm2/hm2_7i92.0:     IO Pin 011 (P2-08): Muxed Encoder #0, pin Muxed A (Input)
hm2/hm2_7i92.0:     IO Pin 012 (P2-09): Muxed Encoder #0, pin Muxed B (Input)
hm2/hm2_7i92.0:     IO Pin 013 (P2-10): Muxed Encoder #0, pin Muxed Shared Index (Input)
hm2/hm2_7i92.0:     IO Pin 014 (P2-11): IOPort
hm2/hm2_7i92.0:     IO Pin 015 (P2-12): IOPort
hm2/hm2_7i92.0:     IO Pin 016 (P2-13): IOPort
hm2/hm2_7i92.0:     IO Pin 017 (P1-01): IOPort
hm2/hm2_7i92.0:     IO Pin 018 (P1-14): IOPort
hm2/hm2_7i92.0:     IO Pin 019 (P1-02): IOPort
hm2/hm2_7i92.0:     IO Pin 020 (P1-15): IOPort
hm2/hm2_7i92.0:     IO Pin 021 (P1-03): IOPort
hm2/hm2_7i92.0:     IO Pin 022 (P1-16): IOPort
hm2/hm2_7i92.0:     IO Pin 023 (P1-04): IOPort
hm2/hm2_7i92.0:     IO Pin 024 (P1-17): IOPort
hm2/hm2_7i92.0:     IO Pin 025 (P1-05): IOPort
hm2/hm2_7i92.0:     IO Pin 026 (P1-06): IOPort
hm2/hm2_7i92.0:     IO Pin 027 (P1-07): IOPort
hm2/hm2_7i92.0:     IO Pin 028 (P1-08): IOPort
hm2/hm2_7i92.0:     IO Pin 029 (P1-09): IOPort
hm2/hm2_7i92.0:     IO Pin 030 (P1-10): IOPort
hm2/hm2_7i92.0:     IO Pin 031 (P1-11): IOPort
hm2/hm2_7i92.0:     IO Pin 032 (P1-12): IOPort
hm2/hm2_7i92.0:     IO Pin 033 (P1-13): IOPort
hm2/hm2_7i92.0: registered
FALSE
FALSE
0
halcmd: sets encoder-quad-enable TRUE
halcmd: hm2/hm2_7i92.0: Encoder 0: quadrature count error
20 Jan 2024 06:07

Install Advice (HOME_USE_INDEX with stepper using an encoder)

Category: Installing LinuxCNC

7i96 lathe update went perfectly, but when I flash the 7i92 mill I'm getting errors running the new 7i92_7i85sx1sdid.bit file.

I tried the --reload, power cycle and the verify comes back ok. I can --readhmid.

FWIW, The mill is running linuxCNC 2.8.4. (Lathe was running 2.9.2)

However, when I run my Mill config with the new .biffile I get:

cncbox@debian:~/linuxcnc/configs/Mill7i85s$ linuxcnc Mill7i85s.ini
LINUXCNC - 2.8.4-23-g93a844ef5
Machine configuration directory is '/home/cncbox/linuxcnc/configs/Mill7i85s'
Machine configuration file is 'Mill7i85s.ini'
Starting LinuxCNC...
application-specific initialization failed: no display name and no $DISPLAY environment variable
Error in startup script: invalid command name "."
    while executing
". configure -borderwidth 0 -highlightthickness 0"
    (file "/usr/lib/tcltk/linuxcnc/bin/popimage" line 35)
twopass:invoked with <> options
twopass:found ./Mill7i85s.hal
twopass:found ./Spindle.hal
twopass:found ./estop-chain.hal
twopass:found ./quad_encoder.hal
twopass:found ./postgui_load.hal
twopass:pass0: loadusr -Wn spindle-vfd gs2_vfd -r 9600 -p none -s 2 --name spindle-vfd --accel-seconds 5 --decel-seconds 3 --braking-resistor --device /dev/ttyUSB0
spindle-vfd: device='/dev/ttyUSB0', baud=9600, parity='N', bits=8, stopbits=2, address=1, enabled=1
twopass:pass0: loadusr -W hal_manualtoolchange
Note: Using POSIX realtime
Traceback (most recent call last):
  File "/usr/bin/hal_manualtoolchange", line 62, in <module>
    app = Tkinter.Tk(className="AxisToolChanger")
  File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 1828, in __init__
    self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
_tkinter.TclError: no display name and no $DISPLAY environment variable
hm2: loading Mesa HostMot2 driver version 0.15
hm2_eth: loading Mesa AnyIO HostMot2 ethernet driver version 0.2
hm2_eth: 10.10.10.10: INFO: Hardware address (MAC): 00:60:1b:13:05:4e
hm2_eth: discovered 7I92
hm2/hm2_7i92.0: Low Level init 0.15
hm2/hm2_7i92.0: Smart Serial Firmware Version 43
hm2/hm2_7i92.0: unknown stepgen MD:
hm2/hm2_7i92.0:     Version = 194, expected 0-2
hm2/hm2_7i92.0:     NumRegisters = 10, expected 10
hm2/hm2_7i92.0:     InstanceStride = 0x00000004, expected 4
hm2/hm2_7i92.0:     MultipleRegisters = 0x000001FF, expected 0x000001FF
hm2/hm2_7i92.0: failed to parse Module Descriptor 6
board fails HM2 registration
hm2_eth: in hm2_eth_reset
hm2_eth: rtapi_app_main: Invalid argument (-22)

twopass: load_the_modules cmd=<orig_loadrt hm2_eth [concat board_ip="10.10.10.10"] [concat config=" num_encoders=4 num_stepgens=4"]>
waitpid failed /usr/bin/rtapi_app hm2_eth
/usr/bin/rtapi_app exited without becoming ready
insmod for hm2_eth failed, returned -1

Shutting down and cleaning up LinuxCNC...
Running HAL shutdown script
hm2: unloading


If I flash a different .bit file the config starts up as normal.
 
Displaying 1 - 2 out of 2 results.
Time to create page: 1.487 seconds
Powered by Kunena Forum