Difference between revisions of "CMSemicon BAT32G133-EVB"
Thomas.haase (talk | contribs) m (Thomas.haase moved page CMSemicon BAT32G1xx EVB to CMSemicon BAT32G133-EVB: Device split) |
|||
(9 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
+ | [[Category:Evalboards]] |
||
__TOC__ |
__TOC__ |
||
− | This article describes specifics for the CMSemicon |
+ | This article describes specifics for the CMSemicon BAT32G133-EVB evaluation board. |
==BAT32G133-EVB== |
==BAT32G133-EVB== |
||
+ | [[File:3244.JPG|600px]] |
||
− | |||
− | '''PICTURE will follow''' |
||
− | |||
− | ==BAT32G157-EVB== |
||
− | |||
− | '''PICTURE will follow''' |
||
== Minimum requirements == |
== Minimum requirements == |
||
− | * J-Link software V7. |
+ | * J-Link software V7.82c or later |
== Preparing for J-Link == |
== Preparing for J-Link == |
||
Line 36: | Line 32: | ||
You can use the following command line:<br> |
You can use the following command line:<br> |
||
− | <code>./JLink.exe -Device |
+ | <code>./JLink.exe -Device BAT32G133GC24SS -If SWD -Speed 4000 -autoconnect 1</code> |
− | |||
− | In case of BAT32G157GK - for other devices adopt the -device setting.<br> |
||
The output should look as follows:<br> |
The output should look as follows:<br> |
||
− | [[File: |
+ | [[File:BAT32G133GC24SS_connect.png|400px]] |
== Example Project== |
== Example Project== |
||
Line 48: | Line 42: | ||
Make sure that the option bytes are configured in a valid configuration.<br> |
Make sure that the option bytes are configured in a valid configuration.<br> |
||
In case of the example programs this has been done by modifying the Cortex_M_Startup.s with the following code:<br> |
In case of the example programs this has been done by modifying the Cortex_M_Startup.s with the following code:<br> |
||
− | <source lang=" |
+ | <source lang="c"> .section .vectors, "a" |
// fill to 0xC0 for the flash configuration field |
// fill to 0xC0 for the flash configuration field |
||
//.fill 0xC0-(_vectors_end-_vectors), 1, 0xFF |
//.fill 0xC0-(_vectors_end-_vectors), 1, 0xFF |
||
.org 0xC0, 0xFF |
.org 0xC0, 0xFF |
||
− | // |
+ | // 0xC0: WDT Control BYTE |
− | // |
+ | // 0xC1: LVD Control BYTE (C1H) |
− | // |
+ | // 0xC2: HOCO Control BYTE (FRQSEL) |
− | // |
+ | // 0xC3: Flash Protect Control BYTE |
− | // |
+ | // 0xC4: Boot Area Control BYTE |
− | // |
+ | // 0xC5: QSPI flash protect option BYTE |
− | // |
+ | // 0xC6: QSPI flash protect option BYTE0 |
− | // |
+ | // 0xC7: QSPI flash protect option BYTE1 |
OptBytes: |
OptBytes: |
||
.byte 0xEF, 0xFF, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF |
.byte 0xEF, 0xFF, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF |
||
Line 66: | Line 60: | ||
It is a simple Hello World sample linked into the internal flash.<br> |
It is a simple Hello World sample linked into the internal flash.<br> |
||
====SETUP==== |
====SETUP==== |
||
− | *J-Link software: |
+ | *J-Link software: V7.82c |
− | *Embedded Studio: |
+ | *Embedded Studio: V6.40 |
− | *Hardware: |
+ | *Hardware: CMSemicon BAT32G133-EVB |
+ | *Link:[[File:BAT32G133GC.zip]] |
||
− | *Link: |
Latest revision as of 15:34, 8 May 2024
This article describes specifics for the CMSemicon BAT32G133-EVB evaluation board.
BAT32G133-EVB
Minimum requirements
- J-Link software V7.82c or later
Preparing for J-Link
- Solder Header to the board (row on the side of the Chip)
Device Side | J-Link Signal | Pin |
---|---|---|
CLK | SWCLK | 9 |
DAT | SWDIO | 7 |
RST | RESET | 15 |
GND | GND | 4 |
VDD | VTRef | 1 |
- Power the board via USB
- Verify the Connection with e.g. J-Link Commander.
You can use the following command line:
./JLink.exe -Device BAT32G133GC24SS -If SWD -Speed 4000 -autoconnect 1
The output should look as follows:
Example Project
The following example project was created with the SEGGER Embedded Studio project wizard.
As the option bytes resides in the normal flash area it's not a good idea just to compile and flash.
Make sure that the option bytes are configured in a valid configuration.
In case of the example programs this has been done by modifying the Cortex_M_Startup.s with the following code:
.section .vectors, "a"
// fill to 0xC0 for the flash configuration field
//.fill 0xC0-(_vectors_end-_vectors), 1, 0xFF
.org 0xC0, 0xFF
// 0xC0: WDT Control BYTE
// 0xC1: LVD Control BYTE (C1H)
// 0xC2: HOCO Control BYTE (FRQSEL)
// 0xC3: Flash Protect Control BYTE
// 0xC4: Boot Area Control BYTE
// 0xC5: QSPI flash protect option BYTE
// 0xC6: QSPI flash protect option BYTE0
// 0xC7: QSPI flash protect option BYTE1
OptBytes:
.byte 0xEF, 0xFF, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF
It is a simple Hello World sample linked into the internal flash.
SETUP
- J-Link software: V7.82c
- Embedded Studio: V6.40
- Hardware: CMSemicon BAT32G133-EVB
- Link:File:BAT32G133GC.zip