cancel
Showing results for 
Search instead for 
Did you mean: 

Automate Production Programming

bsuthar
Associate III

Hello Team,

To address mass Programming of Customized board , Looking help to have Batch File / Python Script which accomplishes Following Task :

1. Flash The Hex file

2. Set RDP1

3. Read UID (96-bit ) of MCU

4. Log UID and Time into CSV

I tried with batch File using STm32Cube Programmer CLI.exe , but Failed to connect with ST-Link.

yes, I am Using SWD Debug Interface. 

I am not sure uf any scripting Template is alraedy ready with CubeProgrammer. 

 

 

12 REPLIES 12

> we were expecting some ready to go script / pointers if you can list out. 

"ready to go script" - no, not how this works.  I don't do your work for you.

"pointers" yes, to help you debug your own application.

If you haven't solved this already, look at the output from the programmer command that you are issuing to read the UID (i.e. UID.txt).  Then verify that your "for" line that parses that file is looking at the correct token.  At least with CubeProgrammer v2.16 is the output isn't what you think.

Pavel A.
Super User

Instead of old batch language you may want to use powershell. It is more powerful for scripting.

bsuthar
Associate III

We treid with Both Powershell and Old command shell, But stuck at some otr other point.

Any way , we found solution by leaving batch script and moving with Python.

it worked seamlessly.

Thank you for your time.