Cursor

From FSI
(Difference between revisions)
Jump to: navigation, search
(FPGA board)
(Getting started)
 
(43 intermediate revisions by 4 users not shown)
Line 6: Line 6:
  
 
== Specification ==
 
== Specification ==
 +
 +
=== Function ===
  
 
The basic specification is the following one:
 
The basic specification is the following one:
* On reset, the cursor moves to the start position given by a Hall sensor close to the DC motor.
+
* When ''restart'' button is pressed, the cursor moves to the start position given by a Hall sensor close to the DC motor.
* When pos 1 button is pressed, the cursor has to accelerate towards position 1, advance with full speed, decelerate and stop at position 1, be it from the start position or from position 2.
+
* When ''pos 1'' button is pressed, the cursor has to accelerate towards position 1, advance with full speed, decelerate and stop at position 1, be it from the start position or from position 2.
* When pos 2 button is pressed, the cursor has to accelerate towards position 2, advance with full speed, decelerate and stop at position 2.
+
* When ''pos 2'' button is pressed, the cursor has to accelerate towards position 2, advance with full speed, decelerate and stop at position 2.
 +
 
 +
[[File:Cursor_range_position_diagram.png|600px|center|Position Range Diagram]]
  
 
The acceleration and deceleration ramps are a function of the position and not of the time.
 
The acceleration and deceleration ramps are a function of the position and not of the time.
Indeed, it would be very difficult to know when to start decelerating to reach one of the positions if the deceleration was to be produced by a counter.
+
Indeed, it would be very difficult to know when to start decelerating to reach one of the positions if the deceleration was based on the time instead of the position.
The slope of the ramp has to be chosen such as the acceleration and deceleration distances are in the order of magnitude of 1 cm.
+
The slope of the ramp has to be chosen such as the acceleration and deceleration distances are in the order of magnitude of 1 cm.
  
 
The positions to reach are:
 
The positions to reach are:
Line 20: Line 24:
 
* position 2 = 12 cm
 
* position 2 = 12 cm
  
The following figure represents the shape of the speed versus position:
+
=== Circuit ===
[[File:Cursor_range_position_diagram.png|800px|center|Position Range Diagram]]
+
 
 +
The circuit controls a DC motor which drives a chariot.
 +
[[File:Cursor system.svg|600px|center|Position Range Diagram]]
 +
 
 +
The circuit works as follows:
 +
* The [[Cursor#DC_motor|DC motor]] is controlled by three signals <code>motorOn</code>, <code>side1</code>, <code>side2</code>. Its speed is controlled by a PWM-modulation.
 +
* There are two [[Cursor#Hall_sensors|Hall-Senors]] at the ends of the rail, which detect the presence of the cursor chariot (<code>sensor1</code>, <code>sensor2</code>).
 +
* The [[Cursor#Encoder|Encoder Module]] is used to count the position of the cursor chariot. Its three encoder outputs, <code>encoderA</code>, <code>encoderB</code> and <code>encoderI</code>, allow to follow the angle of the screw.
 +
* Three [[Cursor#Buttons_and_LEDs|Buttons]] are used to control the system: <code>restart</code>, <code>go1</code> and <code>go2</code>. An additional button, <code>button4</code>, can be used for optional functionality.
 +
* The <code>testOut</code> pins can be used to output additional information from the system, e.g. for debug or in order to drive the [[Cursor#Buttons_and_LEDs|LEDs]]
 +
 
 +
The [[Media:Cursor_Toplevel_Empty.pdf‎|Empty Toplevel Design]] shows all the signals connected to the [[Cursor#FPGA_board|FPGA board]].
  
 
== Components ==
 
== Components ==
The system consists of
+
The system consists of:
* a [[Media:Cursor_chariot_assembly.pdf|chariot assembly]]
+
* a [[Media:Cursor_chariot_assembly.pdf|chariot assembly]] holding an [[Media:Cursor_power_circuit.pdf|electronic board]] driving the motor and reading the sensors
 
* an [http://wiki.hevs.ch/uit/index.php5/Hardware/FPGAEBS FPGA prototyping board]
 
* an [http://wiki.hevs.ch/uit/index.php5/Hardware/FPGAEBS FPGA prototyping board]
* a [[Media:Heb_lcd_schematic.pdf|control board]] with 4 buttons and 8 LEDs
+
* a [http://wiki.hevs.ch/uit/index.php5/Hardware/Parallelport/heb_lcd control board] with 4 buttons and 8 LEDs
  
 
==== Motor control circuit ====
 
==== Motor control circuit ====
The chariot DC motor is powered with 12 V.
+
The chariot DC motor is powered with 12&nbsp;V.
The [[Media:Cursor_power_circuit.pdf|power circuit]] contains an [[Media:L6207N.pdf|H-bridge]] controlled by digital signals.
+
The [[Media:Cursor_power_circuit.pdf|power board]] contains an [[Media:L6207N.pdf|H-bridge]] controlled by digital signals.
On the power board, a 5 V regulator generates the proper voltage for powering the FPGA board.
+
On the power board, a 5&nbsp;V regulator generates the proper voltage for powering the FPGA board.
  
 
===== DC motor =====
 
===== DC motor =====
Line 38: Line 53:
  
 
===== Encoder =====
 
===== Encoder =====
The angle of the screw can be measured with the help of an [[Media:encoder_module.pdf|incremental encoder module]].
+
The angle of the screw can be measured with the help of an [http://en.wikipedia.org/wiki/Rotary_encoder#Incremental_rotary_encoder incremental rotary encoder].
The model used on the assembly is a AEDB-9140-A12, which has 500 Counts Per Revolution (CPR).
+
The model used on the assembly is a [[Media:encoder_module.pdf|AEDB-9140-A12]] which has 500&nbsp;Counts Per Revolution (CPR).
  
 
===== Hall sensors =====
 
===== Hall sensors =====
 +
The hall sensor is a switch which is working with the [http://en.wikipedia.org/wiki/Hall_effect_sensor hall effect]. If a magnet is close to the sensor, the contact closes. On the assembly, 2&nbsp;hall sensors are used to identify the left and right limits of the chariot.
  
 
==== FPGA board ====
 
==== FPGA board ====
The main board is called FPGA-EBS and is a the school main development board. It features many different connectivity and a Xilinx FPGA Spartan xc3s500e.
+
The main board is the school's [http://wiki.hevs.ch/uit/index.php5/Hardware/FPGAEBS FPGA-EBS lab development board]. It hosts a [http://www.xilinx.com/products/silicon-devices/fpga/spartan-3.html Xilinx Spartan xc3s500e FPGA] and features many different interfaces (serial, USB, Ethernet, …).
 
+
For additional information see the [http://wiki.hevs.ch/uit/index.php5/Hardware/FPGAEBS UIT Wiki]
+
  
 
==== Buttons and LEDs ====
 
==== Buttons and LEDs ====
The Button and Led parallelboard can be attached to the FPGA-EBS and has '''4 additional buttons''' and '''8 additional leds''' which you can use.
+
The [http://wiki.hevs.ch/uit/index.php5/Hardware/Parallelport/heb_lcd Buttons and Leds board] is to be attached to the FPGA board.
 +
It has 4 buttons and 8 leds which can be used in the design.
 +
 
 +
== Evaluation ==
 +
The evaluation of the project is done with the help of the [[Media:ELN_labs_evaluation.pdf‎|ELN evaluation sheet]].
  
 
== Getting started ==
 
== Getting started ==
 
In order to start the projects you should do the following:
 
In order to start the projects you should do the following:
 
* Read carefully the specifications above
 
* Read carefully the specifications above
* Consulte the guides for the first steps
+
* Draw the architecture of the circuit in the form of a block diagram
 +
* Consult the guides for the first steps into the design software
 
** [[Cursor/students_fr|Guide en français]]
 
** [[Cursor/students_fr|Guide en français]]
** [[Cursor/students_de|Einführung auf Deutsch]]
+
** [[Cursor/students_de|Anleitung auf Deutsch]]
 +
 
 +
The [[Media:ElN_Tools_Cheatsheet.pdf|EDA tools cheatsheet]] can be a great help for the circuit design and synthesis.
  
 
== Additional Information ==
 
== Additional Information ==
Additional informations for [[cursor/professor|Professor]]
+
 
 +
* [[cursor/survival guide|Survival guide]]
 +
* [[cursor/board combination|Board combinations]]
 +
* Additional informations for [[cursor/professor|collaborators]]
 +
 
 +
[[Category:Bachelor]] [[Category:ElN]] [[Category:Cursor]]

Latest revision as of 10:32, 19 November 2020

Contents

The cursor project is an ElN project done at the end of the first semester. It consists in driving a DC motor which moves the cursor chariot with the help of a screw.

Cursor in Action

Specification

Function

The basic specification is the following one:

  • When restart button is pressed, the cursor moves to the start position given by a Hall sensor close to the DC motor.
  • When pos 1 button is pressed, the cursor has to accelerate towards position 1, advance with full speed, decelerate and stop at position 1, be it from the start position or from position 2.
  • When pos 2 button is pressed, the cursor has to accelerate towards position 2, advance with full speed, decelerate and stop at position 2.
Position Range Diagram

The acceleration and deceleration ramps are a function of the position and not of the time. Indeed, it would be very difficult to know when to start decelerating to reach one of the positions if the deceleration was based on the time instead of the position. The slope of the ramp has to be chosen such as the acceleration and deceleration distances are in the order of magnitude of 1 cm.

The positions to reach are:

  • position 1 = 8 cm
  • position 2 = 12 cm

Circuit

The circuit controls a DC motor which drives a chariot.

Position Range Diagram

The circuit works as follows:

  • The DC motor is controlled by three signals motorOn, side1, side2. Its speed is controlled by a PWM-modulation.
  • There are two Hall-Senors at the ends of the rail, which detect the presence of the cursor chariot (sensor1, sensor2).
  • The Encoder Module is used to count the position of the cursor chariot. Its three encoder outputs, encoderA, encoderB and encoderI, allow to follow the angle of the screw.
  • Three Buttons are used to control the system: restart, go1 and go2. An additional button, button4, can be used for optional functionality.
  • The testOut pins can be used to output additional information from the system, e.g. for debug or in order to drive the LEDs

The Empty Toplevel Design shows all the signals connected to the FPGA board.

Components

The system consists of:

Motor control circuit

The chariot DC motor is powered with 12 V. The power board contains an H-bridge controlled by digital signals. On the power board, a 5 V regulator generates the proper voltage for powering the FPGA board.

DC motor

The DC motor is controlled by a L6207 H-bridge driver.

Encoder

The angle of the screw can be measured with the help of an incremental rotary encoder. The model used on the assembly is a AEDB-9140-A12 which has 500 Counts Per Revolution (CPR).

Hall sensors

The hall sensor is a switch which is working with the hall effect. If a magnet is close to the sensor, the contact closes. On the assembly, 2 hall sensors are used to identify the left and right limits of the chariot.

FPGA board

The main board is the school's FPGA-EBS lab development board. It hosts a Xilinx Spartan xc3s500e FPGA and features many different interfaces (serial, USB, Ethernet, …).

Buttons and LEDs

The Buttons and Leds board is to be attached to the FPGA board. It has 4 buttons and 8 leds which can be used in the design.

Evaluation

The evaluation of the project is done with the help of the ELN evaluation sheet.

Getting started

In order to start the projects you should do the following:

  • Read carefully the specifications above
  • Draw the architecture of the circuit in the form of a block diagram
  • Consult the guides for the first steps into the design software

The EDA tools cheatsheet can be a great help for the circuit design and synthesis.

Additional Information

Personal tools
Namespaces
Variants
Actions
Navigation
Modules / Projects
Browse
Toolbox