8i20 brushless servo hall sensor set up
- johns00056
- Offline
- Premium Member
-
Less
More
- Posts: 108
- Thank you received: 2
02 Apr 2014 01:52 #45486
by johns00056
8i20 brushless servo hall sensor set up was created by johns00056
I am following the instructions in the forum post below.
www.linuxcnc.org/index.php/english/forum...ting-up-5i257i858i20
I finally got it entered into a terminal without error.
Then,nothing happens. The red fault leds on 8i20 and 7i84 stay on.
Is there something else I have to do to turn the boards on while doing a halrun session?
If I start LINUX CNC the red leds go off and the green led blinks, indicating that they are
communicating properly.
loadrt hostmot2
loadrt hm2_pci config="sserial_port_0=0000xxxx"
loadrt threads name1=thread1 period1=1000000
loadrt bldc cfg=h
addf hm2_5i25.0.read thread1
addf bldc.0 thread1
addf hm2_5i25.0.write thread1
addf hm2_5i25.0.pet_watchdog thread1
net h1 hm2_5i25.0.7i84.0.1.input-00 bldc.0.hall1
net h2 hm2_5i25.0.7i84.0.1.input-01 bldc.0.hall2
net h3 hm2_5i25.0.7i84.0.1.input-02 bldc.0.hall3
net ang bldc.0.rotor-angle hm2_5i25.0.8i20.0.0.angle
setp bldc.0.pattern 34
loadusr halmeter signal h1
loadusr halmeter signal h2
loadusr halmeter signal h3
and check that the halls twiddle as you manually rotate the motor.
Now you can apply a small current to the motor and see if it spins. It probably won't as there is only a 1 in 42 chance that "34" was the correct hall pattern.
setp hm2_5i25.0.8i20.0.0.current 0.5
The motor might kick, it might buzz. It might even spin.
Now try all the hall patterns and see which one works best.
www.linuxcnc.org/index.php/english/forum...ting-up-5i257i858i20
I finally got it entered into a terminal without error.
Then,nothing happens. The red fault leds on 8i20 and 7i84 stay on.
Is there something else I have to do to turn the boards on while doing a halrun session?
If I start LINUX CNC the red leds go off and the green led blinks, indicating that they are
communicating properly.
loadrt hostmot2
loadrt hm2_pci config="sserial_port_0=0000xxxx"
loadrt threads name1=thread1 period1=1000000
loadrt bldc cfg=h
addf hm2_5i25.0.read thread1
addf bldc.0 thread1
addf hm2_5i25.0.write thread1
addf hm2_5i25.0.pet_watchdog thread1
net h1 hm2_5i25.0.7i84.0.1.input-00 bldc.0.hall1
net h2 hm2_5i25.0.7i84.0.1.input-01 bldc.0.hall2
net h3 hm2_5i25.0.7i84.0.1.input-02 bldc.0.hall3
net ang bldc.0.rotor-angle hm2_5i25.0.8i20.0.0.angle
setp bldc.0.pattern 34
loadusr halmeter signal h1
loadusr halmeter signal h2
loadusr halmeter signal h3
and check that the halls twiddle as you manually rotate the motor.
Now you can apply a small current to the motor and see if it spins. It probably won't as there is only a 1 in 42 chance that "34" was the correct hall pattern.
setp hm2_5i25.0.8i20.0.0.current 0.5
The motor might kick, it might buzz. It might even spin.
Now try all the hall patterns and see which one works best.
Please Log in or Create an account to join the conversation.
02 Apr 2014 05:38 #45490
by PCW
Replied by PCW on topic 8i20 brushless servo hall sensor set up
I think the original post is missing the "start:" command that starts the thread execution
(man halcmd)
(man halcmd)
Please Log in or Create an account to join the conversation.
- johns00056
- Offline
- Premium Member
-
Less
More
- Posts: 108
- Thank you received: 2
02 Apr 2014 06:37 #45491
by johns00056
Replied by johns00056 on topic 8i20 brushless servo hall sensor set up
I got it working now! It was in the post but I missed it.
I'm not sure about connecting the hall signal wires. The encoder is already powered by 7i85.
I am guessing that the field power supply on 7i84 ( where I want to connect the hall signal input wires) needs to
use the same power supply as 7i85.
I'm not sure about connecting the hall signal wires. The encoder is already powered by 7i85.
I am guessing that the field power supply on 7i84 ( where I want to connect the hall signal input wires) needs to
use the same power supply as 7i85.
Please Log in or Create an account to join the conversation.
02 Apr 2014 11:25 #45495
by PCW
Replied by PCW on topic 8i20 brushless servo hall sensor set up
Yes if the hall signals a 5V signals you will need to use 5V Vfield for at least 1/2 of the 7I84 I/O
Please Log in or Create an account to join the conversation.
02 Apr 2014 19:01 - 02 Apr 2014 19:44 #45500
by andypugh
That sounds a bit painful.
An alternative is to copy from the forum into gedit, make any required changes, then save the file as (for example) test.hal.
Then:
Will save some typing.
Replied by andypugh on topic 8i20 brushless servo hall sensor set up
I finally got it entered into a terminal without error..
That sounds a bit painful.
An alternative is to copy from the forum into gedit, make any required changes, then save the file as (for example) test.hal.
Then:
halrun
source test.hal
start
Will save some typing.
Last edit: 02 Apr 2014 19:44 by BigJohnT. Reason: fix quote tag
Please Log in or Create an account to join the conversation.
- johns00056
- Offline
- Premium Member
-
Less
More
- Posts: 108
- Thank you received: 2
09 Apr 2014 02:25 - 09 Apr 2014 03:48 #45712
by johns00056
Replied by johns00056 on topic 8i20 brushless servo hall sensor set up
Thanks for all the help, I am still working on this.
I have tried almost all of the hall patterns and nothing happens, other than a very faint
wine at the motor with every pattern.
The halmeters indicate that h1 h2 h3 are working.
The 8i20 current halmeter won't go higher than 1 or -1 no matter what value I enter in
the halcmd.
The 8i20 amp enable shows false, but I don't know what to do about that.
The motor runs OK in linux cnc without the halls in cfg=qi
I think that I have the encoder oriented properly. I powered the motor with a car battery positive to U and negative to V and W, then turned the encoder until my digital voltmeter display jumped a little while connected between Z and Z-.
www.galco.com/techdoc/dnhr/f152048_80910_cp.pdf
loadrt hostmot2
loadrt hm2_pci config="sserial_port_0=0000xxxx"
loadrt threads name1=thread1 period1=1000000
loadrt bldc cfg=h
addf hm2_5i25.0.read thread1
addf bldc.0 thread1
addf hm2_5i25.0.write thread1
addf hm2_5i25.0.pet_watchdog thread1
net h1 hm2_5i25.0.7i84.0.1.input-24 bldc.0.hall1
net h2 hm2_5i25.0.7i84.0.1.input-25 bldc.0.hall2
net h3 hm2_5i25.0.7i84.0.1.input-26 bldc.0.hall3
net ang bldc.0.rotor-angle hm2_5i25.0.8i20.0.0.angle
setp bldc.0.pattern 21
loadusr halmeter signal hm2_5i25.0.8i20.0.0
loadusr halmeter signal h1
loadusr halmeter signal h2
loadusr halmeter signal h3
setp hm2_5i25.0.8i20.0.0.current 4.5
start
halcmd: show all *8i20*
Loaded HAL Components:
ID Type Name PID State
Component Pins:
Owner Type Dir Value Name
5 bit IN FALSE hm2_5i25.0.8i20.0.0.amp_enable
5 float IN 0.5 hm2_5i25.0.8i20.0.0.angle <== ang
5 u32 OUT 0x003C0000 hm2_5i25.0.8i20.0.0.comms
5 float IN 1 hm2_5i25.0.8i20.0.0.current
5 u32 OUT 0x00000000 hm2_5i25.0.8i20.0.0.fault
5 u32 OUT 0x00000200 hm2_5i25.0.8i20.0.0.status
5 float OUT 17 hm2_5i25.0.8i20.0.0.temp
5 float OUT 59.52 hm2_5i25.0.8i20.0.0.voltage
Pin Aliases:
Alias Original Name
Signals:
Type Value Name (linked to)
Parameters:
Owner Type Dir Value Name
5 float RW 7.5 hm2_5i25.0.8i20.0.0.max_current
5 u32 RW 0x0A00006B hm2_5i25.0.8i20.0.0.serial_number
Parameter Aliases:
Alias Original Name
Exported Functions:
Owner CodeAddr Arg FP Users Name
Realtime Threads:
Period FP Name ( Time, Max-Time )
I have tried almost all of the hall patterns and nothing happens, other than a very faint
wine at the motor with every pattern.
The halmeters indicate that h1 h2 h3 are working.
The 8i20 current halmeter won't go higher than 1 or -1 no matter what value I enter in
the halcmd.
The 8i20 amp enable shows false, but I don't know what to do about that.
The motor runs OK in linux cnc without the halls in cfg=qi
I think that I have the encoder oriented properly. I powered the motor with a car battery positive to U and negative to V and W, then turned the encoder until my digital voltmeter display jumped a little while connected between Z and Z-.
www.galco.com/techdoc/dnhr/f152048_80910_cp.pdf
loadrt hostmot2
loadrt hm2_pci config="sserial_port_0=0000xxxx"
loadrt threads name1=thread1 period1=1000000
loadrt bldc cfg=h
addf hm2_5i25.0.read thread1
addf bldc.0 thread1
addf hm2_5i25.0.write thread1
addf hm2_5i25.0.pet_watchdog thread1
net h1 hm2_5i25.0.7i84.0.1.input-24 bldc.0.hall1
net h2 hm2_5i25.0.7i84.0.1.input-25 bldc.0.hall2
net h3 hm2_5i25.0.7i84.0.1.input-26 bldc.0.hall3
net ang bldc.0.rotor-angle hm2_5i25.0.8i20.0.0.angle
setp bldc.0.pattern 21
loadusr halmeter signal hm2_5i25.0.8i20.0.0
loadusr halmeter signal h1
loadusr halmeter signal h2
loadusr halmeter signal h3
setp hm2_5i25.0.8i20.0.0.current 4.5
start
halcmd: show all *8i20*
Loaded HAL Components:
ID Type Name PID State
Component Pins:
Owner Type Dir Value Name
5 bit IN FALSE hm2_5i25.0.8i20.0.0.amp_enable
5 float IN 0.5 hm2_5i25.0.8i20.0.0.angle <== ang
5 u32 OUT 0x003C0000 hm2_5i25.0.8i20.0.0.comms
5 float IN 1 hm2_5i25.0.8i20.0.0.current
5 u32 OUT 0x00000000 hm2_5i25.0.8i20.0.0.fault
5 u32 OUT 0x00000200 hm2_5i25.0.8i20.0.0.status
5 float OUT 17 hm2_5i25.0.8i20.0.0.temp
5 float OUT 59.52 hm2_5i25.0.8i20.0.0.voltage
Pin Aliases:
Alias Original Name
Signals:
Type Value Name (linked to)
Parameters:
Owner Type Dir Value Name
5 float RW 7.5 hm2_5i25.0.8i20.0.0.max_current
5 u32 RW 0x0A00006B hm2_5i25.0.8i20.0.0.serial_number
Parameter Aliases:
Alias Original Name
Exported Functions:
Owner CodeAddr Arg FP Users Name
Realtime Threads:
Period FP Name ( Time, Max-Time )
Last edit: 09 Apr 2014 03:48 by johns00056.
Please Log in or Create an account to join the conversation.
09 Apr 2014 05:35 #45723
by andypugh
Replied by andypugh on topic 8i20 brushless servo hall sensor set up
Very puzzing.
I am away from home until the weekend, but when I get back I will try your config on something and see what I get.
I am away from home until the weekend, but when I get back I will try your config on something and see what I get.
Please Log in or Create an account to join the conversation.
- johns00056
- Offline
- Premium Member
-
Less
More
- Posts: 108
- Thank you received: 2
12 Apr 2014 17:28 #45879
by johns00056
Replied by johns00056 on topic 8i20 brushless servo hall sensor set up
Do I need to use an encoder counter for the halls?
PCW said, in another thread, that 7i85 won't work for this because of something about muxed encoders.
I am using standard inputs on 7i84 for the halls.
PCW said, in another thread, that 7i85 won't work for this because of something about muxed encoders.
I am using standard inputs on 7i84 for the halls.
Please Log in or Create an account to join the conversation.
12 Apr 2014 19:24 #45883
by andypugh
No, the Hall sensors normally connect to standard inputs. The torque is smoother if you also use encoders (qh mode) but it ought to work with just Hall sensors in "h" mode.
Replied by andypugh on topic 8i20 brushless servo hall sensor set up
Do I need to use an encoder counter for the halls?
PCW said, in another thread, that 7i85 won't work for this because of something about muxed encoders.
I am using standard inputs on 7i84 for the halls.
No, the Hall sensors normally connect to standard inputs. The torque is smoother if you also use encoders (qh mode) but it ought to work with just Hall sensors in "h" mode.
Please Log in or Create an account to join the conversation.
12 Apr 2014 22:06 #45888
by PCW
Replied by PCW on topic 8i20 brushless servo hall sensor set up
Can you check that (with drive disabled)
bldc.0.rotor-angle increments in steps of 0.1666 as you rotate the motor shaft? (and goes from 0,833333 back to 0)
This will verify that the halls are being read properly and you have at least one a few working patterns
If this works, you should also verify that bldc.0.rotor-angle in 'h' mode counts
in the same direction relative to shaft rotation as the (working) 'q' mode
This really should not be this hard
Do you have the Fanuc encoder part number (A06B-860 - something)
They might actually make this easier at the expense of having to use LinuxCNC master
bldc.0.rotor-angle increments in steps of 0.1666 as you rotate the motor shaft? (and goes from 0,833333 back to 0)
This will verify that the halls are being read properly and you have at least one a few working patterns
If this works, you should also verify that bldc.0.rotor-angle in 'h' mode counts
in the same direction relative to shaft rotation as the (working) 'q' mode
This really should not be this hard
Do you have the Fanuc encoder part number (A06B-860 - something)
They might actually make this easier at the expense of having to use LinuxCNC master
Please Log in or Create an account to join the conversation.
Time to create page: 0.089 seconds