<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/">
	<channel>
		<title><![CDATA[EmBitz - Scripts]]></title>
		<link>https://www.embitz.org/forum/</link>
		<description><![CDATA[EmBitz - https://www.embitz.org/forum]]></description>
		<pubDate>Fri, 24 Apr 2026 08:39:09 +0000</pubDate>
		<generator>MyBB</generator>
		<item>
			<title><![CDATA[Scripts to support Atmel SAM3 chips]]></title>
			<link>https://www.embitz.org/forum/thread-166.html</link>
			<pubDate>Thu, 20 Apr 2023 16:18:01 +0200</pubDate>
			<dc:creator><![CDATA[<a href="https://www.embitz.org/forum/member.php?action=profile&uid=203">jdubois</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.embitz.org/forum/thread-166.html</guid>
			<description><![CDATA[Here are some scripts for the ATSAM3xx line of Atmel/Microchip chips.  Boy were these easier than the NXP LPC scripts.  I don't know why NXP made their chip flashing procedure so difficult.<br />
<br />
I also made a small change to the Cortex-M0 section in the atmel-auto.script so that it wouldn't incorrectly detect non-Atmel chips as Atmel when using the auto.script.<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.embitz.org/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=162" target="_blank" title="">sam3.zip</a> (Size: 5.17 KB / Downloads: 53)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[Here are some scripts for the ATSAM3xx line of Atmel/Microchip chips.  Boy were these easier than the NXP LPC scripts.  I don't know why NXP made their chip flashing procedure so difficult.<br />
<br />
I also made a small change to the Cortex-M0 section in the atmel-auto.script so that it wouldn't incorrectly detect non-Atmel chips as Atmel when using the auto.script.<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.embitz.org/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=162" target="_blank" title="">sam3.zip</a> (Size: 5.17 KB / Downloads: 53)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Scripts to support NXP LPC chips]]></title>
			<link>https://www.embitz.org/forum/thread-162.html</link>
			<pubDate>Wed, 12 Apr 2023 17:18:31 +0200</pubDate>
			<dc:creator><![CDATA[<a href="https://www.embitz.org/forum/member.php?action=profile&uid=203">jdubois</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.embitz.org/forum/thread-162.html</guid>
			<description><![CDATA[Here are my scripts for supporting the LPC line of chips.  They seem to be working ok, but I can't guarantee they're perfect as they haven't seen a huge ton of testing.  I've tested them on an LPC802, LPC1115, and LPC1769.  Other chips in those three lines should work as well, but most of them will need their IDs added to the device lookup functions.  I did not update the main auto.script to check for LPC devices, as I suspect the ID check would upset non-LPC chips.  I've got an idea for a less invasive check, but haven't implemented it yet.<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.embitz.org/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=155" target="_blank" title="">nxpscripts.zip</a> (Size: 13.84 KB / Downloads: 50)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[Here are my scripts for supporting the LPC line of chips.  They seem to be working ok, but I can't guarantee they're perfect as they haven't seen a huge ton of testing.  I've tested them on an LPC802, LPC1115, and LPC1769.  Other chips in those three lines should work as well, but most of them will need their IDs added to the device lookup functions.  I did not update the main auto.script to check for LPC devices, as I suspect the ID check would upset non-LPC chips.  I've got an idea for a less invasive check, but haven't implemented it yet.<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.embitz.org/forum/images/attachtypes/zip.png" title="ZIP File" border="0" alt=".zip" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=155" target="_blank" title="">nxpscripts.zip</a> (Size: 13.84 KB / Downloads: 50)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Scripting API documentation?]]></title>
			<link>https://www.embitz.org/forum/thread-161.html</link>
			<pubDate>Tue, 11 Apr 2023 14:24:29 +0200</pubDate>
			<dc:creator><![CDATA[<a href="https://www.embitz.org/forum/member.php?action=profile&uid=203">jdubois</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.embitz.org/forum/thread-161.html</guid>
			<description><![CDATA[Interested in seeing if we can get some documentation of the APIs for the Squirrel scripts in EBlink.  Most of it can be figured out by looking at the existing scripts, however that does lead to some unanswered questions.]]></description>
			<content:encoded><![CDATA[Interested in seeing if we can get some documentation of the APIs for the Squirrel scripts in EBlink.  Most of it can be figured out by looking at the existing scripts, however that does lead to some unanswered questions.]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[NXP LPC802 Flashing]]></title>
			<link>https://www.embitz.org/forum/thread-160.html</link>
			<pubDate>Tue, 11 Apr 2023 14:22:50 +0200</pubDate>
			<dc:creator><![CDATA[<a href="https://www.embitz.org/forum/member.php?action=profile&uid=203">jdubois</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.embitz.org/forum/thread-160.html</guid>
			<description><![CDATA[Working with some custom scripts I've written to use NXP LPC chips with EBlink, I've run into a stumbling point.<br />
<br />
The LPC802 chip has 16K of flash arranged as either 16 sectors of 1K each, or 256 pages of 64 bytes each.  The last two pages (254 &amp; 255) are mapped on the chip to ROM instead of the flash, so you cannot program them.   Using the 1024 byte sector arrangement instead of the 64 byte page arrangement is much faster to erase and program. But using this, the last sector is actually 896 bytes instead of 1024.  There doesn't seem to be any good way to tell EBlink about this uneven sized final sector.<br />
<br />
The first approach is to simply use the 64 byte page arrangement.  This works, but is very slow to erase and write 256 individual pages.<br />
<br />
The second approach is to use the 1K sector arrangement and just ignore the fact that the last 128 bytes of the last sector aren't written.  This also mostly works, but when EBlink reads the last sector (usually when deciding if it needs to be programmed) it will read back the ROM bytes in those last 128 bytes and so it will never match what is in the file to be flashed (forcing the last sector to always be erased and reprogrammed).<br />
<br />
The best approach, I believe, would be to set up two separate flash areas in the EBlink memory map.  The first with 15 1K sectors, and the second with 14 64 byte sectors.  This would give the speed of using the sectors for most of the chip, but the granularity on the last sector to avoid the 128 ROM bytes.  (This approach would also be helpful looking toward the LPC1700 series of chips, as they have two different flash sections with different sector sizes.) However, it appears that EBlink only uses the first flash section in the memory map when erasing/programming the chip.]]></description>
			<content:encoded><![CDATA[Working with some custom scripts I've written to use NXP LPC chips with EBlink, I've run into a stumbling point.<br />
<br />
The LPC802 chip has 16K of flash arranged as either 16 sectors of 1K each, or 256 pages of 64 bytes each.  The last two pages (254 &amp; 255) are mapped on the chip to ROM instead of the flash, so you cannot program them.   Using the 1024 byte sector arrangement instead of the 64 byte page arrangement is much faster to erase and program. But using this, the last sector is actually 896 bytes instead of 1024.  There doesn't seem to be any good way to tell EBlink about this uneven sized final sector.<br />
<br />
The first approach is to simply use the 64 byte page arrangement.  This works, but is very slow to erase and write 256 individual pages.<br />
<br />
The second approach is to use the 1K sector arrangement and just ignore the fact that the last 128 bytes of the last sector aren't written.  This also mostly works, but when EBlink reads the last sector (usually when deciding if it needs to be programmed) it will read back the ROM bytes in those last 128 bytes and so it will never match what is in the file to be flashed (forcing the last sector to always be erased and reprogrammed).<br />
<br />
The best approach, I believe, would be to set up two separate flash areas in the EBlink memory map.  The first with 15 1K sectors, and the second with 14 64 byte sectors.  This would give the speed of using the sectors for most of the chip, but the granularity on the last sector to avoid the 128 ROM bytes.  (This approach would also be helpful looking toward the LPC1700 series of chips, as they have two different flash sections with different sector sizes.) However, it appears that EBlink only uses the first flash section in the memory map when erasing/programming the chip.]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Add STM32U5 and STM32L5 support]]></title>
			<link>https://www.embitz.org/forum/thread-131.html</link>
			<pubDate>Fri, 22 Jul 2022 18:49:15 +0200</pubDate>
			<dc:creator><![CDATA[<a href="https://www.embitz.org/forum/member.php?action=profile&uid=247">Buzzwang</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.embitz.org/forum/thread-131.html</guid>
			<description><![CDATA[Hello,<br />
<br />
basicly I'm using a selfmade cmake based buildchain and using EMBitz only for debuging by passing the .elf file to it.<br />
I have bought 2 nucleo boards. Both are not suppoerted, yet. I would like to add the both devices myself, just by copy&amp;paste&amp;replace. But I'm not sure about the different core M33.<br />
I also tried to check EBLink-github for updates, but I cannot reach it.<br />
<br />
<br />
ST-LINK SN  : 002B004F3331510A33323639<br />
ST-LINK FW  : V3J8M3<br />
Board      : NUCLEO-U575ZI-Q<br />
Voltage    : 3.30V<br />
SWD freq    : 24000 KHz<br />
Connect mode: Normal<br />
Reset mode  : Software reset<br />
Device ID  : 0x482<br />
Revision ID : Rev X<br />
Device name : STM32U575/STM32U585<br />
Flash size  : 2 MBytes<br />
Device type : MCU<br />
Device CPU  : Cortex-M33<br />
BL Version  : 0x92<br />
Debug in Low Power mode enabled<br />
<br />
Interface USB# : 002B004F3331510A33323639<br />
Interface type : STlink/V3<br />
STlink connect : Under reset<br />
Target voltage : 3.30V<br />
Interface speed: 24000KHz<br />
Target detected: Cortex-M33 (r0p4) with FPv5_SP<br />
HW breakpoints : 8<br />
HW watchpoints : 4<br />
Fault unwind  : Active break (level 2)<br />
<br />
Error unsupported STM32 ID: 0x482<br />
<br />
Please report this ID so that we can add it.<br />
<br />
-------------------------------------------------------<br />
<br />
ST-LINK SN  : 066CFF505352716587121640<br />
ST-LINK FW  : V2J37M26<br />
Board      : NUCLEO-L552ZE-Q<br />
Voltage    : 3.24V<br />
SWD freq    : 4000 KHz<br />
Connect mode: Normal<br />
Reset mode  : Software reset<br />
Device ID  : 0x472<br />
Revision ID : Rev B<br />
Device name : STM32L5xx<br />
Flash size  : 512 KBytes<br />
Device type : MCU<br />
Device CPU  : Cortex-M33<br />
BL Version  : --<br />
<br />
<br />
Interface USB# : 066CFF505352716587121640<br />
Interface type : STlink/V2.1<br />
STlink connect : Under reset<br />
Target voltage : 3.24V<br />
Interface speed: 4000KHz<br />
Target detected: Cortex-M33 (r0p2) with FPv5_SP<br />
HW breakpoints : 8<br />
HW watchpoints : 4<br />
Fault unwind  : Active break (level 2)<br />
<br />
<br />
Please report this ID so that we can add it.]]></description>
			<content:encoded><![CDATA[Hello,<br />
<br />
basicly I'm using a selfmade cmake based buildchain and using EMBitz only for debuging by passing the .elf file to it.<br />
I have bought 2 nucleo boards. Both are not suppoerted, yet. I would like to add the both devices myself, just by copy&amp;paste&amp;replace. But I'm not sure about the different core M33.<br />
I also tried to check EBLink-github for updates, but I cannot reach it.<br />
<br />
<br />
ST-LINK SN  : 002B004F3331510A33323639<br />
ST-LINK FW  : V3J8M3<br />
Board      : NUCLEO-U575ZI-Q<br />
Voltage    : 3.30V<br />
SWD freq    : 24000 KHz<br />
Connect mode: Normal<br />
Reset mode  : Software reset<br />
Device ID  : 0x482<br />
Revision ID : Rev X<br />
Device name : STM32U575/STM32U585<br />
Flash size  : 2 MBytes<br />
Device type : MCU<br />
Device CPU  : Cortex-M33<br />
BL Version  : 0x92<br />
Debug in Low Power mode enabled<br />
<br />
Interface USB# : 002B004F3331510A33323639<br />
Interface type : STlink/V3<br />
STlink connect : Under reset<br />
Target voltage : 3.30V<br />
Interface speed: 24000KHz<br />
Target detected: Cortex-M33 (r0p4) with FPv5_SP<br />
HW breakpoints : 8<br />
HW watchpoints : 4<br />
Fault unwind  : Active break (level 2)<br />
<br />
Error unsupported STM32 ID: 0x482<br />
<br />
Please report this ID so that we can add it.<br />
<br />
-------------------------------------------------------<br />
<br />
ST-LINK SN  : 066CFF505352716587121640<br />
ST-LINK FW  : V2J37M26<br />
Board      : NUCLEO-L552ZE-Q<br />
Voltage    : 3.24V<br />
SWD freq    : 4000 KHz<br />
Connect mode: Normal<br />
Reset mode  : Software reset<br />
Device ID  : 0x472<br />
Revision ID : Rev B<br />
Device name : STM32L5xx<br />
Flash size  : 512 KBytes<br />
Device type : MCU<br />
Device CPU  : Cortex-M33<br />
BL Version  : --<br />
<br />
<br />
Interface USB# : 066CFF505352716587121640<br />
Interface type : STlink/V2.1<br />
STlink connect : Under reset<br />
Target voltage : 3.24V<br />
Interface speed: 4000KHz<br />
Target detected: Cortex-M33 (r0p2) with FPv5_SP<br />
HW breakpoints : 8<br />
HW watchpoints : 4<br />
Fault unwind  : Active break (level 2)<br />
<br />
<br />
Please report this ID so that we can add it.]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[STM32G0B1xx/0C1xx support]]></title>
			<link>https://www.embitz.org/forum/thread-119.html</link>
			<pubDate>Mon, 28 Mar 2022 18:33:04 +0200</pubDate>
			<dc:creator><![CDATA[<a href="https://www.embitz.org/forum/member.php?action=profile&uid=23">PDonchev</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.embitz.org/forum/thread-119.html</guid>
			<description><![CDATA[STM32G0B1xx/0C1xx support. The script should recognize a dual bank, but I haven't tested it.<br />
No support for RAM/FLASH ECC. I had to pre-configure the OBs with STM32CubeProgrammer to avoid starting of the system bootloader. BOOT0 pin is shared with SWDCLK. These MCUs are not supported in ST-Link Utility software.<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.embitz.org/forum/images/attachtypes/txt.png" title="EBlink script" border="0" alt=".script" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=132" target="_blank" title="">stm32gx.script</a> (Size: 8.41 KB / Downloads: 113)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.embitz.org/forum/images/attachtypes/txt.png" title="EBlink script" border="0" alt=".script" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=131" target="_blank" title="">stm32-auto.script</a> (Size: 6.18 KB / Downloads: 97)
<!-- end: postbit_attachments_attachment -->]]></description>
			<content:encoded><![CDATA[STM32G0B1xx/0C1xx support. The script should recognize a dual bank, but I haven't tested it.<br />
No support for RAM/FLASH ECC. I had to pre-configure the OBs with STM32CubeProgrammer to avoid starting of the system bootloader. BOOT0 pin is shared with SWDCLK. These MCUs are not supported in ST-Link Utility software.<br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.embitz.org/forum/images/attachtypes/txt.png" title="EBlink script" border="0" alt=".script" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=132" target="_blank" title="">stm32gx.script</a> (Size: 8.41 KB / Downloads: 113)
<!-- end: postbit_attachments_attachment --><br /><!-- start: postbit_attachments_attachment -->
<br /><!-- start: attachment_icon -->
<img src="https://www.embitz.org/forum/images/attachtypes/txt.png" title="EBlink script" border="0" alt=".script" />
<!-- end: attachment_icon -->&nbsp;&nbsp;<a href="attachment.php?aid=131" target="_blank" title="">stm32-auto.script</a> (Size: 6.18 KB / Downloads: 97)
<!-- end: postbit_attachments_attachment -->]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[EBlink on STM32G4 dependance on DBANK option]]></title>
			<link>https://www.embitz.org/forum/thread-8.html</link>
			<pubDate>Wed, 08 Jul 2020 07:06:31 +0200</pubDate>
			<dc:creator><![CDATA[<a href="https://www.embitz.org/forum/member.php?action=profile&uid=92">Misc01</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.embitz.org/forum/thread-8.html</guid>
			<description><![CDATA[I'm using Embitz with EBlink to debug a STM32G4 controller. The G4 family offers an option byte called DBANK that controls whether the flash memory is organised in one single bank with 128 bit granularity (option bit unchecked) or in dual bank mode with 64bit granularity. When the controller is configured to single bank mode, EBlink often stops with an error when updating the software. This does not happen in dual bank configuration. When I use the STM32CubeProgrammer to perform a full chip erase before programming, the effect does not show at all.<br />
<br />
Maybe this is related to the fact that the Flash erase function in STs library (<span style="color: #333333;" class="mycode_color"><span style="font-size: small;" class="mycode_size"><span style="font-family: Tahoma, Verdana, Arial, sans-serif;" class="mycode_font">HAL_FLASHEx_Erase</span></span></span>) requires consideration of the DBANK setting on how to pass the block number to be erased.]]></description>
			<content:encoded><![CDATA[I'm using Embitz with EBlink to debug a STM32G4 controller. The G4 family offers an option byte called DBANK that controls whether the flash memory is organised in one single bank with 128 bit granularity (option bit unchecked) or in dual bank mode with 64bit granularity. When the controller is configured to single bank mode, EBlink often stops with an error when updating the software. This does not happen in dual bank configuration. When I use the STM32CubeProgrammer to perform a full chip erase before programming, the effect does not show at all.<br />
<br />
Maybe this is related to the fact that the Flash erase function in STs library (<span style="color: #333333;" class="mycode_color"><span style="font-size: small;" class="mycode_size"><span style="font-family: Tahoma, Verdana, Arial, sans-serif;" class="mycode_font">HAL_FLASHEx_Erase</span></span></span>) requires consideration of the DBANK setting on how to pass the block number to be erased.]]></content:encoded>
		</item>
		<item>
			<title><![CDATA[Tip: Unlock locked devices with EBlink]]></title>
			<link>https://www.embitz.org/forum/thread-3.html</link>
			<pubDate>Mon, 27 Apr 2020 07:41:25 +0200</pubDate>
			<dc:creator><![CDATA[<a href="https://www.embitz.org/forum/member.php?action=profile&uid=1">embitz</a>]]></dc:creator>
			<guid isPermaLink="false">https://www.embitz.org/forum/thread-3.html</guid>
			<description><![CDATA[If you have a locked device it is rather simple to write an unlock script. You don't need all the flash functions and XML memory mapping because you don't need to use the flash (-F) or GDB (-G) module. Just write your script and us the "main" script function as your entry.<br />
<br />
./EBlink -I stlink -S myUnlock]]></description>
			<content:encoded><![CDATA[If you have a locked device it is rather simple to write an unlock script. You don't need all the flash functions and XML memory mapping because you don't need to use the flash (-F) or GDB (-G) module. Just write your script and us the "main" script function as your entry.<br />
<br />
./EBlink -I stlink -S myUnlock]]></content:encoded>
		</item>
	</channel>
</rss>