How to connect a stepper with 2 Coil?
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hello,
You need something like a dual H-Bridge driver to allow you to push and pull on all four stepper motor pins.
Something like this would do.
http://www.matrixtsl.com/webshop/e-bloc ... board.html
The datasheet shows you the schematic.
http://www.matrixtsl.com/resources/getr ... php?id=887
Something like an L298D would also do the job but as this is transistor based and not FET based you will loose more voltage in the driver IC itself and therefore the driver IC will be able to drive less current and will get hotter.
You need something like a dual H-Bridge driver to allow you to push and pull on all four stepper motor pins.
Something like this would do.
http://www.matrixtsl.com/webshop/e-bloc ... board.html
The datasheet shows you the schematic.
http://www.matrixtsl.com/resources/getr ... php?id=887
Something like an L298D would also do the job but as this is transistor based and not FET based you will loose more voltage in the driver IC itself and therefore the driver IC will be able to drive less current and will get hotter.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hi Ben
I have for the 4 pins a driver.
I use the pin B9,B8,B4,B3
the pin B9,B8 has a nice signal but the B4,B3 are always high.
If I use "output" for
B4,B3 and set them to low ,they are still always high.
I have for the 4 pins a driver.
I use the pin B9,B8,B4,B3
the pin B9,B8 has a nice signal but the B4,B3 are always high.
If I use "output" for
B4,B3 and set them to low ,they are still always high.
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Ok what chip are you using and can you post a simple test program so we can have a look.the pin B9,B8 has a nice signal but the B4,B3 are always high.
If I use "output" for
B4,B3 and set them to low ,they are still always high.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hi Ben
The PIC32MX440F256H
I made a board with 4pcs 9Pol connector
The connector 1 is for stepper nr:1
pin B9,B8,B4,B3
The connector 2 is for stepper nr:2
pin E6,E7,F1,B12
I wrote a small program and the stepper 2 is moving 360deg and 360deg back
but the stepper 1 has a Problem with B4,B3. This pin are always high.
I hope it's possible to use "generic stepper" from matrix, because the simulation with the stepper and and my 3D parts is working nice and it's realy a big advantage from FC7.
The PIC32MX440F256H
I made a board with 4pcs 9Pol connector
The connector 1 is for stepper nr:1
pin B9,B8,B4,B3
The connector 2 is for stepper nr:2
pin E6,E7,F1,B12
I wrote a small program and the stepper 2 is moving 360deg and 360deg back
but the stepper 1 has a Problem with B4,B3. This pin are always high.
I hope it's possible to use "generic stepper" from matrix, because the simulation with the stepper and and my 3D parts is working nice and it's realy a big advantage from FC7.
- Attachments
-
- stepper_erni1-for-matrix.fcfx
- (32.25 KiB) Downloaded 413 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hello,
The B4 and B3 problem may already be fixed by applying the latest files from here.
http://www.matrixtsl.com/mmforums/viewt ... 63&t=18209
Hopefully once the pins are fixed then everything should then work as expected.
The B4 and B3 problem may already be fixed by applying the latest files from here.
http://www.matrixtsl.com/mmforums/viewt ... 63&t=18209
Hopefully once the pins are fixed then everything should then work as expected.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hi Ben
I did the update, but still the same.
The RB4 is on the same pin as C1IN-/CN6
"AN4/C1IN-/CN6/RB4"
Is there a problem with "Comparator 1 Negative Input"?
I did the update, but still the same.
The RB4 is on the same pin as C1IN-/CN6
"AN4/C1IN-/CN6/RB4"
Is there a problem with "Comparator 1 Negative Input"?
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Yes the stepper motor generic should be able to do the same thing as you're doing in your program.
Please can you post an example where you are controlling the B3 and B4 pins. I can't see anything that would cause an issue but there may be something lurking in the code.
Please can you post an example where you are controlling the B3 and B4 pins. I can't see anything that would cause an issue but there may be something lurking in the code.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
I'm using now the stepper (nema8) Model from FC.
It's working on the connector 2 this is for stepper nr:2
pin E6,E7,F1,B12
The connector 1 is for stepper nr:1
pin B9,B8,B4,B3
is still not working because of B4,B3
I prepare now a software with 2 stepper and send it to you.
It's working on the connector 2 this is for stepper nr:2
pin E6,E7,F1,B12
The connector 1 is for stepper nr:1
pin B9,B8,B4,B3
is still not working because of B4,B3
I prepare now a software with 2 stepper and send it to you.
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hi Ben
here is the Code
Stepper 1 is not working
here is the Code
Stepper 1 is not working
- Attachments
-
- stepper_erni2-for-matrix.fcfx
- (33.03 KiB) Downloaded 392 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Thanks I'm investigating now.
If you change your C code to the following does this help at all?
If you change your C code to the following does this help at all?
Code: Select all
DDPCON=0;
CM1CON=0;
CM2CON=0;
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hi Ben
I insert the 3 line but still the same problem with the Pin B4,B3
regards
Stefan
I insert the 3 line but still the same problem with the Pin B4,B3
regards
Stefan
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hmm in the Manual I found a part I dont understand. maybe You can help me.
How can I Usb "not enable" ?
How can I Usb "not enable" ?
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: How to connect a stepper with 2 Coil?
I think to disable USB would be.
However this should be set to 0 automatically after a reset, unless the chip you're using has a USB bootloader which is not cleaning up after itself.
Code: Select all
U1CON = 0;
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
I think You are right
I found this in the manual and of corse I dont now to remove or turn off .......
"
Connect your device in bootloader mode to the computer (for PIC32-PINGUINO-MICRO hold
BUT and press RST after connected). Start the IDE from it's shortcut. .........
"
I found this in the manual and of corse I dont now to remove or turn off .......
"
Connect your device in bootloader mode to the computer (for PIC32-PINGUINO-MICRO hold
BUT and press RST after connected). Start the IDE from it's shortcut. .........
"
- Attachments
-
- PIC32-PINGUINO-MICRO-Revision-A.pdf
- (748.41 KiB) Downloaded 284 times
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hi Ben
I have further configured the inputs and outputs from the board. Also the input from the switch for the bootloader and some more. Now it works.
thank you for the friendly help.
regards
Stefan
I have further configured the inputs and outputs from the board. Also the input from the switch for the bootloader and some more. Now it works.
thank you for the friendly help.
regards
Stefan
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Great glad you've got it working now.
Do you know if the problem was related to the hardware or the bootloader?
If Bootloader related what commands did you have to use to get the pins working correctly?
Do you know if the problem was related to the hardware or the bootloader?
If Bootloader related what commands did you have to use to get the pins working correctly?
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
- Contact:
Re: How to connect a stepper with 2 Coil?
Hi Ben
Now it's clear, it was a problem in the hardware I did. It was never a problem of FC. Sorry.
Stefan
Now it's clear, it was a problem in the hardware I did. It was never a problem of FC. Sorry.
Stefan