aboutsummaryrefslogtreecommitdiff
path: root/codegen/lib/utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'codegen/lib/utils.py')
-rw-r--r--codegen/lib/utils.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/codegen/lib/utils.py b/codegen/lib/utils.py
index 3887bb35..c3d293c0 100644
--- a/codegen/lib/utils.py
+++ b/codegen/lib/utils.py
@@ -18,9 +18,11 @@ def to_camel_case(name: str):
s = f'_{s}'
return s
+
def upper_first_letter(name: str):
return name[0].upper() + name[1:]
+
def padded_hex(n: int):
return f'0x{n:02x}'
@@ -55,4 +57,4 @@ def group_packets(packets: list[PacketIdentifier]):
def get_dir_location(name: str):
- return os.path.join(os.path.dirname(__file__), '..', name)
+ return os.path.join(os.path.dirname(os.path.dirname(__file__)), name)