Difference between revisions of "Motor Driver Interface"
Jump to navigation
Jump to search
(Creation of the page.) |
|||
Line 1: | Line 1: | ||
− | + | ==Parts== | |
+ | |||
+ | Part numbers listed are those of the Digi Key Corporation parts database. Note - some generic parts do not have part numbers listed. | ||
+ | |||
+ | ===Processor=== | ||
+ | |||
+ | *[[ATTINY26-16SI-ND]] - U3 - Atmel [http://en.wikipedia.org/wiki/Avr AVR] Microcontroller | ||
+ | *LED2 - Green LED for use by programs running on the microcontroller | ||
+ | *R3 - 470 ohm resistor in series with LED2 | ||
+ | |||
+ | ===Data I/O=== | ||
+ | |||
+ | ====To Motor Driver==== | ||
+ | |||
+ | *MC74HC164ADR2OSCT-ND - U6 - 8 bit shift register, converts serial data from SPI to parallel data for the motor drivers | ||
+ | |||
+ | ====From Switches==== | ||
+ | |||
+ | *296-1212-1-ND - U7 - Inverter with Schmitt Trigger, reduces bounce noise from the switches | ||
+ | *399-2127-ND - C6,C7,C8 - 0.1 microfarad capacitors | ||
+ | *770-61-R10K-ND - RN1 - Resistor network provides pullup voltages for button signals | ||
+ | |||
+ | ====From Voltage Sensor==== | ||
+ | |||
+ | *R4 - 10k ohm resistor on voltage sensor signal | ||
+ | *R5 - 82k ohm resistor on voltage sensor signal | ||
+ | *399-2127-ND - C9 - 0.1 microfarad capacitor | ||
+ | |||
+ | ===CAN Specific=== | ||
+ | |||
+ | *[[MCP2515]] - U2 - Microchip CAN Controller with [http://en.wikipedia.org/wiki/Serial_Peripheral_Interface SPI] Interface | ||
+ | *[[MCP2551]] - U1 - Microchip CAN TransponderP966-ND | ||
+ | *R1 - 10k ohm pullup resistor for the RESET command | ||
+ | *R9 - 10k ohm pullup resistor for the CAN chip select | ||
+ | |||
+ | ===Onboard Power Control=== | ||
+ | |||
+ | *[[296-12290-1-ND]] - U4 - 5V Linear Regulator | ||
+ | *1N4004GICT-ND - D1 - Diode | ||
+ | *P966-ND - C1,C2 - 10 microfarad Capacitor | ||
+ | *399-2127-ND - C3,C4,C5 - 0.1 microfarad Capacitor | ||
+ | *LED1 - Red LED to indicate power activity | ||
+ | *R2 - 470 ohm resistor in series with LED1 | ||
+ | |||
+ | ===Oscillator=== | ||
+ | |||
+ | *300-7022-1-ND - U4 - 11.0592 MHZ Clock Siqnal Oscillator | ||
+ | |||
+ | ===Receptacles=== | ||
+ | |||
+ | *A19490-ND - J1 - Power 2-pin receptacle | ||
+ | *A19491-ND - J2 - CAN 3-pin receptacle | ||
+ | *MHB16K-ND - J3 - 16 pin header for connecting to a motor drive | ||
+ | *A19520-ND - J4 - SPI connection to the MCU, 10 pin header | ||
+ | *A19431-ND - J5 - 4 pin receptacle connecting a current/voltage sensor signal to the MCU | ||
+ | *A19432-ND - J6 - 5 pin receptacle connecting the start, stop, manual, and auto driving controls to the MCU | ||
+ | |||
+ | ===Misc.=== | ||
+ | |||
+ | *377-1090-ND - Box to contain the module | ||
+ | *1892K-ND - Standoffs | ||
+ | |||
+ | ==Electrical== | ||
+ | |||
+ | [[Image:MDIF Schematic.png]] | ||
+ | [[Image:MDIF Board.png]] | ||
+ | |||
+ | ===Port Pin Assignments on MCU=== | ||
+ | |||
+ | * Port A: | ||
+ | * Bit Dir Description | ||
+ | * 0 O Vantec strobe | ||
+ | * 1 I Auto/Manual switch: 0=Manual, 1=Auto | ||
+ | * 2 I Remote: 0=Run, 1=Stop | ||
+ | * 3 I BRB: 0=Stop, 1=Run | ||
+ | * 4 Unused | ||
+ | * 5 I Battery current input (analog, ADC4) | ||
+ | * 6 I Battery voltage input (analog, ADC5) | ||
+ | * 7 O Status LED | ||
+ | * | ||
+ | * Port B: | ||
+ | * Bit Dir Description | ||
+ | * 0 I SPI data input, with pull-up | ||
+ | * 1 O SPI data output | ||
+ | * 2 O SPI clock | ||
+ | * 3 O CAN /CS | ||
+ | * 4 I Clock, not usable as I/O | ||
+ | * 5 Unused | ||
+ | * 6 I CAN INT | ||
+ | * 7 I /RESET, not usable as I/O | ||
+ | |||
+ | |||
+ | ==Code== | ||
+ | |||
+ | ===C Source Files=== | ||
+ | |||
+ | *acd.c - analog - to - digital sampling | ||
+ | |||
+ | *can.c - communicates with the CAN controller, pretty much the same for all modules | ||
+ | |||
+ | *Makefile - programmer created file for configuring the compilation for gcc | ||
+ | |||
+ | *mdif.c - contains all control information for the motor drivers | ||
+ | |||
+ | *spi_usi - hardware based spi |
Revision as of 03:51, 21 January 2006
Contents
Parts
Part numbers listed are those of the Digi Key Corporation parts database. Note - some generic parts do not have part numbers listed.
Processor
- ATTINY26-16SI-ND - U3 - Atmel AVR Microcontroller
- LED2 - Green LED for use by programs running on the microcontroller
- R3 - 470 ohm resistor in series with LED2
Data I/O
To Motor Driver
- MC74HC164ADR2OSCT-ND - U6 - 8 bit shift register, converts serial data from SPI to parallel data for the motor drivers
From Switches
- 296-1212-1-ND - U7 - Inverter with Schmitt Trigger, reduces bounce noise from the switches
- 399-2127-ND - C6,C7,C8 - 0.1 microfarad capacitors
- 770-61-R10K-ND - RN1 - Resistor network provides pullup voltages for button signals
From Voltage Sensor
- R4 - 10k ohm resistor on voltage sensor signal
- R5 - 82k ohm resistor on voltage sensor signal
- 399-2127-ND - C9 - 0.1 microfarad capacitor
CAN Specific
- MCP2515 - U2 - Microchip CAN Controller with SPI Interface
- MCP2551 - U1 - Microchip CAN TransponderP966-ND
- R1 - 10k ohm pullup resistor for the RESET command
- R9 - 10k ohm pullup resistor for the CAN chip select
Onboard Power Control
- 296-12290-1-ND - U4 - 5V Linear Regulator
- 1N4004GICT-ND - D1 - Diode
- P966-ND - C1,C2 - 10 microfarad Capacitor
- 399-2127-ND - C3,C4,C5 - 0.1 microfarad Capacitor
- LED1 - Red LED to indicate power activity
- R2 - 470 ohm resistor in series with LED1
Oscillator
- 300-7022-1-ND - U4 - 11.0592 MHZ Clock Siqnal Oscillator
Receptacles
- A19490-ND - J1 - Power 2-pin receptacle
- A19491-ND - J2 - CAN 3-pin receptacle
- MHB16K-ND - J3 - 16 pin header for connecting to a motor drive
- A19520-ND - J4 - SPI connection to the MCU, 10 pin header
- A19431-ND - J5 - 4 pin receptacle connecting a current/voltage sensor signal to the MCU
- A19432-ND - J6 - 5 pin receptacle connecting the start, stop, manual, and auto driving controls to the MCU
Misc.
- 377-1090-ND - Box to contain the module
- 1892K-ND - Standoffs
Electrical
Port Pin Assignments on MCU
* Port A: * Bit Dir Description * 0 O Vantec strobe * 1 I Auto/Manual switch: 0=Manual, 1=Auto * 2 I Remote: 0=Run, 1=Stop * 3 I BRB: 0=Stop, 1=Run * 4 Unused * 5 I Battery current input (analog, ADC4) * 6 I Battery voltage input (analog, ADC5) * 7 O Status LED * * Port B: * Bit Dir Description * 0 I SPI data input, with pull-up * 1 O SPI data output * 2 O SPI clock * 3 O CAN /CS * 4 I Clock, not usable as I/O * 5 Unused * 6 I CAN INT * 7 I /RESET, not usable as I/O
Code
C Source Files
- acd.c - analog - to - digital sampling
- can.c - communicates with the CAN controller, pretty much the same for all modules
- Makefile - programmer created file for configuring the compilation for gcc
- mdif.c - contains all control information for the motor drivers
- spi_usi - hardware based spi