generated header file as well
This commit is contained in:
Submodule generators/modgen updated: af383e7f14...236aaf71ea
@ -11,8 +11,7 @@ On Windows, Build Tools installation might be necessary
|
||||
import datetime
|
||||
|
||||
from modgen.objects.objects import sql_object_exporter, ObjectDefinitionParser, write_translation_file, \
|
||||
export_object_file
|
||||
from modgen.utility.csv_writer import CsvWriter
|
||||
export_object_file, write_translation_header_file
|
||||
from modgen.utility.printer import PrettyPrinter
|
||||
from modgen.utility.file_management import copy_file, move_file
|
||||
from modgen.utility.sql_writer import SQL_DATABASE_NAME
|
||||
@ -28,6 +27,8 @@ MOVE_CSV = True
|
||||
GENERATE_CPP = True
|
||||
COPY_CPP = True
|
||||
|
||||
GENERATE_HEADER = True
|
||||
|
||||
BSP_SELECT = BspType.BSP_Q7S
|
||||
|
||||
BSP_DIR_NAME = BSP_SELECT.value
|
||||
@ -41,6 +42,7 @@ else:
|
||||
|
||||
CSV_MOVE_DESTINATION = "../"
|
||||
CPP_FILENAME = "translateObjects.cpp"
|
||||
CPP_H_FILENAME = "translateObjects.h"
|
||||
CSV_OBJECT_FILENAME = "mib_objects.csv"
|
||||
FILE_SEPARATOR = ";"
|
||||
|
||||
@ -100,6 +102,9 @@ def handle_file_export(list_items):
|
||||
if COPY_CPP:
|
||||
print("ObjectParser: Copying object file to " + CPP_COPY_DESTINATION)
|
||||
copy_file(CPP_FILENAME, CPP_COPY_DESTINATION)
|
||||
if GENERATE_HEADER:
|
||||
write_translation_header_file(filename=CPP_H_FILENAME)
|
||||
copy_file(filename=CPP_H_FILENAME, destination=CPP_COPY_DESTINATION)
|
||||
if GENERATE_CSV:
|
||||
print("ObjectParser: Generating text export.")
|
||||
export_object_file(filename=CSV_OBJECT_FILENAME, object_list=list_items, file_separator=FILE_SEPARATOR)
|
||||
|
@ -2,7 +2,7 @@
|
||||
* @brief Auto-generated object translation file.
|
||||
* @details
|
||||
* Contains 60 translations.
|
||||
* Generated on: 2021-05-17 19:02:48
|
||||
* Generated on: 2021-05-17 19:11:51
|
||||
*/
|
||||
#include "translateObjects.h"
|
||||
|
||||
|
8
generators/objects/translateObjects.h
Normal file
8
generators/objects/translateObjects.h
Normal file
@ -0,0 +1,8 @@
|
||||
#ifndef FSFWCONFIG_OBJECTS_TRANSLATEOBJECTS_H_
|
||||
#define FSFWCONFIG_OBJECTS_TRANSLATEOBJECTS_H_
|
||||
|
||||
#include <fsfw/objectmanager/SystemObjectIF.h>
|
||||
|
||||
const char* translateObject(object_id_t object);
|
||||
|
||||
#endif /* FSFWCONFIG_OBJECTS_TRANSLATEOBJECTS_H_ */
|
Binary file not shown.
Reference in New Issue
Block a user