Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
tp-ecg-etudiant-y23kammo
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tp-vhdl-mee
MEDCON
gr-vhdl-y23kammo
tp-ecg-etudiant-y23kammo
Commits
045e5b09
Commit
045e5b09
authored
1 month ago
by
KAMMOUN Yanis
Browse files
Options
Downloads
Patches
Plain Diff
Upload New File
parent
1d42f945
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
VHDL/ecgUnit.vhd
+146
-0
146 additions, 0 deletions
VHDL/ecgUnit.vhd
with
146 additions
and
0 deletions
VHDL/ecgUnit.vhd
0 → 100644
+
146
−
0
View file @
045e5b09
-------------------------------------------------------------------------------
-- Title : firUnit
-- Project :
-------------------------------------------------------------------------------
-- File : operativeUnit.vhd
-- Author : Jean-Noel BAZIN <jnbazin@pc-disi-026.enst-bretagne.fr>
-- Company :
-- Created : 2018-04-11
-- Last update: 2018-04-11
-- Platform :
-- Standard : VHDL'93/02
-------------------------------------------------------------------------------
-- Description: 8 bit FIR
-------------------------------------------------------------------------------
-- Copyright (c) 2018
-------------------------------------------------------------------------------
-- Revisions :
-- Date Version Author Description
-- 2018-04-11 1.0 jnbazin Created
-------------------------------------------------------------------------------
library
ieee
;
use
ieee
.
std_logic_1164
.
all
;
use
ieee
.
numeric_std
.
all
;
entity
firUnit
is
port
(
I_clock
:
in
std_logic
;
-- global clock
I_reset
:
in
std_logic
;
-- asynchronous global reset
I_inputSample
:
in
std_logic_vector
(
7
downto
0
);
-- 8 bit input sample
I_inputSampleValid
:
in
std_logic
;
O_filteredSample
:
out
std_logic_vector
(
7
downto
0
);
-- filtered sample
O_filteredSampleValid
:
out
std_logic
);
end
entity
firUnit
;
architecture
archi_firUnit
of
firUnit
is
component
controlUnit
is
port
(
I_clock
:
in
std_logic
;
-- global clock
I_reset
:
in
std_logic
;
-- asynchronous global reset
I_inputSampleValid
:
in
std_logic
;
-- Control signal to load the input sample in the sample shift register and shift the register
I_GprocessingDone
:
in
std_logic
;
I_BprocessingDone
:
in
std_logic
;
I_AprocessingDone
:
in
std_logic
;
I_HprocessingDone
:
in
std_logic
;
O_loadShiftX
:
out
std_logic
;
-- filtered sample
O_loadShiftY
:
out
std_logic
;
-- filtered sample
O_loadShiftz
:
out
std_logic
;
-- filtered sample
O_initAddress
:
out
std_logic
;
-- Control signal to initialize register read address
O_incrAddress
:
out
std_logic
;
-- Control signal to increment register read address
O_initSum
:
out
std_logic
;
-- Control signal to initialize the MAC register
O_loadSum
:
out
std_logic
;
-- Control signal to load the MAC register;
O_loadY
:
out
std_logic
;
-- Control signal to load Y register
O_FilteredSampleValid
:
out
std_logic
;
-- Data valid signal for filtered sample
O_samples
:
out
std_logic_vector
(
1
to
0
);
-- Data signal to select samples
O_coeffs
:
out
std_logic_vector
(
1
to
0
));
-- Data signal to select coefficients
end
component
controlUnit
;
component
operativeUnit
is
port
(
I_clock
:
in
std_logic
;
-- global clock
I_reset
:
in
std_logic
;
-- asynchronous global reset
I_inputSample
:
in
std_logic_vector
(
10
downto
0
);
-- 8 bit input sample
I_loadShiftX
:
in
std_logic
;
-- filtered sample
I_loadShiftY
:
in
std_logic
;
-- filtered sample
I_loadShiftz
:
in
std_logic
;
-- filtered sample
I_initAddress
:
in
std_logic
;
-- Control signal to initialize register read address
I_incrAddress
:
in
std_logic
;
-- Control signal to increment register read address
I_initSum
:
in
std_logic
;
-- Control signal to initialize the MAC register
I_loadSum
:
in
std_logic
;
-- Control signal to load the MAC register;
I_loadY
:
in
std_logic
;
-- Control signal to load Y register
I_samples
:
in
std_logic_vector
(
1
to
0
);
-- Data signal to select X or Y samples (and B or A coefficients)
I_coeffs
:
in
std_logic_vector
(
1
to
0
);
-- Data signal to select coefficients
O_GprocessingDone
:
out
std_logic
;
O_BprocessingDone
:
out
std_logic
;
O_AprocessingDone
:
out
std_logic
;
O_HprocessingDone
:
out
std_logic
;
O_Y
:
out
std_logic_vector
(
10
downto
0
)
-- filtered sample
);
end
component
operativeUnit
;
signal
SC_GprocessingDone
:
std_logic
;
signal
SC_BprocessingDone
:
std_logic
;
signal
SC_AprocessingDone
:
std_logic
;
signal
SC_HprocessingDone
:
std_logic
;
signal
SC_loadShiftX
:
std_logic
;
signal
SC_loadShiftY
:
std_logic
;
signal
SC_loadShiftZ
:
std_logic
;
signal
SC_initAddress
:
std_logic
;
signal
SC_incrAddress
:
std_logic
;
signal
SC_initSum
:
std_logic
;
signal
SC_loadSum
:
std_logic
;
signal
SC_loadY
:
std_logic
;
signal
SC_samples
:
std_logic_vector
(
1
to
0
);
signal
SC_coeffs
:
std_logic_vector
(
1
to
0
);
begin
controlUnit_1
:
entity
work
.
controlUnit
port
map
(
I_clock
=>
I_clock
,
I_reset
=>
I_reset
,
I_inputSampleValid
=>
I_inputSampleValid
,
I_GprocessingDone
=>
SC_GprocessingDone
,
I_BprocessingDone
=>
SC_BprocessingDone
,
I_AprocessingDone
=>
SC_AprocessingDone
,
I_HprocessingDone
=>
SC_HprocessingDone
,
O_loadShiftX
=>
SC_loadShiftX
,
O_loadShiftY
=>
SC_loadShiftY
,
O_loadShiftZ
=>
SC_loadShiftZ
,
O_initAddress
=>
SC_initAddress
,
O_incrAddress
=>
SC_incrAddress
,
O_initSum
=>
SC_initSum
,
O_loadSum
=>
SC_loadSum
,
O_loadY
=>
SC_loadY
,
O_samples
=>
SC_samples
,
O_coeffs
=>
SC_coeffs
,
O_FilteredSampleValid
=>
O_FilteredSampleValid
);
operativeUnit_1
:
entity
work
.
operativeUnit
port
map
(
I_clock
=>
I_clock
,
I_reset
=>
I_reset
,
I_inputSample
=>
I_inputSample
,
I_loadShiftX
=>
SC_loadShiftX
,
I_loadShiftY
=>
SC_loadShiftY
,
I_loadShiftZ
=>
SC_loadShiftZ
,
I_initAddress
=>
SC_initAddress
,
I_incrAddress
=>
SC_incrAddress
,
I_initSum
=>
SC_initSum
,
I_loadSum
=>
SC_loadSum
,
I_loadY
=>
SC_loadY
,
I_samples
=>
SC_samples
,
I_coeffs
=>
SC_coeffs
,
O_GprocessingDone
=>
SC_GprocessingDone
,
O_BprocessingDone
=>
SC_BprocessingDone
,
O_AprocessingDone
=>
SC_AprocessingDone
,
O_HprocessingDone
=>
SC_HprocessingDone
,
O_Y
=>
O_filteredSample
);
end
architecture
archi_firUnit
;
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment