Numerous fixes for Python scripts
This commit is contained in:
@@ -57,7 +57,7 @@ def getNumberOfTransactions(dbconnection):
|
||||
|
||||
def getTraceEndTime(dbconnection):
|
||||
cursor = dbconnection.cursor()
|
||||
cursor.execute("SELECT TraceEnd FROM GeneralInfo")
|
||||
cursor.execute("SELECT MAX(PhaseEnd) FROM Phases")
|
||||
result = cursor.fetchone()
|
||||
return result[0]
|
||||
|
||||
@@ -103,7 +103,7 @@ def getPseudoChannelMode(connection):
|
||||
|
||||
|
||||
def maximum_data_rate(connection):
|
||||
memspec = MemSpec(connection)
|
||||
memspec = MemSpec(connection)
|
||||
try:
|
||||
width = memspec.getIntValue("memarchitecturespec", "nbrOfDevices") * memspec.getIntValue("memarchitecturespec", "width")
|
||||
except:
|
||||
@@ -162,6 +162,6 @@ def get_total_time_in_phase(connection, phase):
|
||||
|
||||
def getCommandLengthForPhase(connection, phase):
|
||||
cursor = connection.cursor()
|
||||
cursor.execute("SELECT " + phase + " FROM CommandLengths")
|
||||
cursor.execute(f"SELECT Length FROM CommandLengths WHERE Command=\"{phase}\"")
|
||||
length = cursor.fetchone()
|
||||
return length[0]
|
||||
|
||||
Reference in New Issue
Block a user