Browse code

Add source code of the assembler compiler

Pawel Jablonski authored on 14/12/2022 19:04:16
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,27 @@
1
+#ifndef ASM_H
2
+#define ASM_H
3
+
4
+#include <QString>
5
+#include <QTextStream>
6
+
7
+#include "datalist.h"
8
+#include "parser.h"
9
+#include "compiler.h"
10
+#include "linker.h"
11
+
12
+//! This class contains assembler start functions
13
+class Asm
14
+{
15
+	public:
16
+		Asm();
17
+
18
+		bool compileRom(const QString &inputFile, const QString &outputFile, const QString &outputMapFile);
19
+		bool compileApp(const QString &inputFile, const QString &outputFile);
20
+
21
+	private:
22
+		bool compile(DataList::Mode mode, QString inputFile, QString outputFile,  QString outputMapFile = "");
23
+
24
+		void initInstructions(Compiler &compiler);
25
+};
26
+
27
+#endif