OpenCores
URL https://opencores.org/ocsvn/steppermotordrive/steppermotordrive/trunk

Subversion Repositories steppermotordrive

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /
    from Rev 11 to Rev 12
    Reverse comparison

Rev 11 → Rev 12

/tags/v1_1_1_1/StepperMotorDrive.ucf
0,0 → 1,15
NET clock LOC = P181;
NET clock PERIOD = 40; # 40ns = 25MHz
NET stepdrive<0> LOC = P25;
NET stepdrive<1> LOC = P26;
NET stepdrive<2> LOC = P27;
NET stepdrive<3> LOC = P28;
NET Direction LOC = P29;
NET Direction PULLUP;
NET StepEnable LOC = P31;
NET StepEnable PULLUP;
# NET ProvideStaticHolding LOC = P32;
# NET ProvideStaticHolding PULLUP;
 
 
 
/tags/v1_1_1_1/StepperMotorDrive.vhd
0,0 → 1,93
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
 
-- c2003 Franks Development, LLC
-- http://www.franks-development.com
-- !This source is distributed under the terms & conditions specified at opencores.org
--
-- Please see the file "StepperMotorWiring.bmp" for info on connecting 4 & 6
-- wire motors to your device. This source should drive either type, though connection
-- to 4-wire motors requires significantly more FET's to buffer outputs. The
-- circuitry for 6-wire motors is more straightforward.
--
-- Another practical consideration is the threshold voltage of the FET's used to
-- buffer the logic outputs & provide current drive to the motor. Most power
-- FET's have a threshold voltage in the 5-12V range (or even higher),
-- while logic devices now run in the 3.3V and lower range. Thus, you must be
-- careful to choose a FET with a low threshold voltage, or a level-converter must
-- be utilized between the logic output and the gate of the drive FET's.
--
-- One of the most advantageous abilities of stepper motors is the ability to
-- provide static holding force in any position. Of course this consumes power
-- and heats the motor up significantly (though steppers are rated to handle this)
-- use of the "static holding" input port will specify this behavior.
 
entity StepperMotorPorts is
Port (
StepDrive : out std_logic_vector(3 downto 0);
clock : in std_logic;
Direction : in std_logic;
StepEnable : in std_logic --;
--ProvideStaticHolding : in std_logic
);
end StepperMotorPorts;
 
architecture StepDrive of StepperMotorPorts is
 
signal state : std_logic_vector(1 downto 0);
signal StepCounter : std_logic_vector(31 downto 0);
constant StepLockOut : std_logic_vector(31 downto 0) := "00000000000000110000110101000000";
 
begin
 
process(clock)
begin
 
if ( (clock'Event) and (clock = '1') ) then
 
StepCounter <= StepCounter + "0000000000000000000000000000001";
 
if (StepCounter >= StepLockOut) then
 
StepCounter <= "00000000000000000000000000000000";
 
StepDrive <= "0000";
if (StepEnable = '1') then
if (Direction = '1') then state <= state + "01"; end if;
if (Direction = '0') then state <= state - "01"; end if;
 
case state is
 
when "00" =>
 
StepDrive <= "1010";
when "01" =>
StepDrive <= "1001";
when "10" =>
StepDrive <= "0101";
when "11" =>
StepDrive <= "0110";
when others =>
 
end case; --state
end if;
end if;
 
end if;
 
end process;
 
end StepDrive;
/tags/v1_1_1_1/StepperMotor.npl
0,0 → 1,28
JDF G
// Created by Project Navigator ver 1.0
PROJECT StepperMotor
DESIGN steppermotor
DEVFAM xpla3
DEVFAMTIME 0
DEVICE xcr3256xl
DEVICETIME 0
DEVPKG PQ208
DEVPKGTIME 1058382337
DEVSPEED -7
DEVSPEEDTIME 0
DEVTOPLEVELMODULETYPE HDL
TOPLEVELMODULETYPETIME 0
DEVSYNTHESISTOOL XST (VHDL/Verilog)
SYNTHESISTOOLTIME 0
DEVSIMULATOR Other
SIMULATORTIME 0
DEVGENERATEDSIMULATIONMODEL VHDL
GENERATEDSIMULATIONMODELTIME 0
SOURCE StepperMotorDrive.vhd
DEPASSOC steppermotorports StepperMotorDrive.ucf
[Normal]
p_CPLDFitunused=xstvhd, xpla3, Implementation.t_vm6File, 1058395051, Float
p_impactConfigFileName=xstvhd, xpla3, Implementation.t_impactProgrammingTool, 1058541585, C:\Projects\Commutator\Firmware\commutatorports.jed
p_impactConfigMode=xstvhd, xpla3, Implementation.t_impactProgrammingTool, 1058383577, Boundary Scan
[STRATEGY-LIST]
Normal=True
/tags/v1_1_1_1/StepperMotorWiring.bmp Cannot display: file marked as a binary type. svn:mime-type = application/octet-stream
tags/v1_1_1_1/StepperMotorWiring.bmp Property changes : Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.