From 6033cc604d21cf047d22173d51cb9855efc83b89 Mon Sep 17 00:00:00 2001 From: Jesse Cirimelli-Low Date: Tue, 8 Jan 2019 18:54:20 -0800 Subject: [PATCH] stable, but incomplete flaskless table gen rewrite --- compiler/datasheet/datasheet.py | 5 +++-- compiler/datasheet/datasheet_gen.py | 25 +++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 2 deletions(-) diff --git a/compiler/datasheet/datasheet.py b/compiler/datasheet/datasheet.py index 726e9920..5e724512 100644 --- a/compiler/datasheet/datasheet.py +++ b/compiler/datasheet/datasheet.py @@ -1,3 +1,4 @@ +from table_gen import * from flask_table import * from operating_conditions import * from characterization_corners import * @@ -63,8 +64,8 @@ class datasheet(): self.html += '

'+ 'Git commit id: ' + str(self.git_id) + '

' self.html +='

Ports and Configuration (DEBUG)

' - self.html += in_out(self.io,table_id='data').__html__().replace('<','<').replace('"','"').replace('>',">") - + #self.html += in_out(self.io,table_id='data').__html__().replace('<','<').replace('"','"').replace('>',">") + self.html += self.io_table.to_html() # for row in self.io_table.rows: # print(row) diff --git a/compiler/datasheet/datasheet_gen.py b/compiler/datasheet/datasheet_gen.py index b97981fa..59d58551 100644 --- a/compiler/datasheet/datasheet_gen.py +++ b/compiler/datasheet/datasheet_gen.py @@ -145,8 +145,33 @@ def parse_characterizer_csv(sram,f,pages): item.max = str(math.floor(1000/float(MIN_PERIOD))) except Exception: pass + # + for item in sheet.operating_table.rows: + #check if the new corner data is worse than the previous worse corner data + if item[0] == 'Operating Temperature': + if float(TEMP) > float(ite[3]): + item[2] = item[3] + item[3] = TEMP + if float(TEMP) < float(item[1]): + item[2] = item[1] + item[1] = TEMP + if item[0] == 'Power supply (VDD) range': + if float(VOLT) > float(item[3]): + item[2] = item[3] + item[3] = VOLT + if float(VOLT) < float(item[1]): + item[2] = item[1] + item[1] = VOLT + + if item.parameter == 'Operating Frequncy (F)': + try: + if float(math.floor(1000/float(MIN_PERIOD)) < float(item[3])): + item[3] = str(math.floor(1000/float(MIN_PERIOD))) + except Exception: + pass + # while(True): if(row[col].startswith('DIN')):