URL
https://opencores.org/ocsvn/sdhc-sc-core/sdhc-sc-core/trunk
Subversion Repositories sdhc-sc-core
Compare Revisions
- This comparison shows the changes necessary to convert path
/sdhc-sc-core/trunk/src/grpSdVerification/unitSdCoreTransferFunction
- from Rev 157 to Rev 158
- ↔ Reverse comparison
Rev 157 → Rev 158
/src/SdCoreTransferFunction.sv
3,6 → 3,7
|
`include "SdCoreTransaction.sv"; |
`include "ExpectedResult.sv"; |
`include "Logger.sv"; |
|
class SdCoreTransferFunction; |
|
21,9 → 22,39
task run(); |
while (StopAfter != 0) begin |
SdCoreTransaction transaction; |
ExpectedResult res = new(); |
|
TransInMb.get(transaction); |
res.trans = transaction; |
|
case(transaction.kind) |
SdCoreTransaction::readSingleBlock: |
begin |
res.RamActions = new[1]; |
res.RamActions[0] = new(); |
res.RamActions[0].Kind = RamAction::Read; |
res.RamActions[0].Addr = transaction.startAddr; |
Log.note("TF: Handle data"); |
end |
|
SdCoreTransaction::writeSingleBlock: |
begin |
res.RamActions = new[1]; |
res.RamActions[0] = new(); |
res.RamActions[0].Kind = RamAction::Read; |
res.RamActions[0].Addr = transaction.startAddr; |
res.RamActions[0].Data = transaction.data[0]; |
end |
default: |
begin |
string msg; |
$swrite(msg, "TF: Transaction kind %s not handled.", transaction.kind.name()); |
Log.error(msg); |
end |
endcase |
|
ExpectedResultOutMb.put(res); |
|
if (StopAfter > 0) StopAfter--; |
end |
endtask |