File tree 1 file changed +6
-2
lines changed
1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -715,6 +715,7 @@ def main() -> int:
715
715
elif config ['ameba' ]['MODEL' ] == 'Z2' :
716
716
shell .run_cmd (
717
717
f"cd { config ['ameba' ]['AMEBA_SDK' ]} /project/realtek_amebaz2_v0_example/GCC-RELEASE" )
718
+ shell .run_cmd ("rm -f project_include.mk" )
718
719
with open (f"{ config ['ameba' ]['AMEBA_SDK' ]} /project/realtek_amebaz2_v0_example/GCC-RELEASE/project_include.mk" , "w" ) as f :
719
720
f .write (textwrap .dedent (f"""\
720
721
SAMPLE_NAME = { options .sample_device_type_name }
@@ -840,8 +841,11 @@ def main() -> int:
840
841
shell .run_cmd (
841
842
f"{ config ['ameba' ]['AMEBA_SDK' ]} /tools/AmebaD/Image_Tool_Linux/flash.sh { config ['ameba' ]['TTY' ]} { config ['ameba' ]['AMEBA_SDK' ]} /project/realtek_amebaD_va0_example/GCC-RELEASE/out" , raise_on_returncode = False )
842
843
else :
843
- flush_print (
844
- "Ameba Z2 currently does not support flashing image through script, stil WIP" )
844
+ shell .run_cmd (f"cd { _CHEF_SCRIPT_PATH } /ameba" )
845
+ shell .run_cmd (
846
+ f"cd { config ['ameba' ]['AMEBA_SDK' ]} /tools/AmebaZ2/Image_Tool_Linux" )
847
+ shell .run_cmd (
848
+ f"{ config ['ameba' ]['AMEBA_SDK' ]} /tools/AmebaZ2/Image_Tool_Linux/flash.sh { config ['ameba' ]['TTY' ]} { config ['ameba' ]['AMEBA_SDK' ]} /project/realtek_amebaz2_v0_example/GCC-RELEASE/application_is/Debug/bin" , raise_on_returncode = False )
845
849
846
850
#
847
851
# Terminal interaction
You can’t perform that action at this time.
0 commit comments