Difference: MecrispCubeWB5M (1 vs. 13)

Revision 132022-12-01 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 83 to 83
 
Mecrisp-Stellaris RA 2.5.4 by Matthias Koch.

Changed:
<
<
Mecrisp-Cube 1.4.5 for STM32WB Discovery, 63/384 KiB RAM/FLASH dictionary (C) 2022 peter@spyr.ch * Firmware Package STM32Cube FW_WB V1.11.0, USB-CDC, BLE Stack 5.3 (C) 2022 STMicroelectronics
>
>
Mecrisp-Cube 1.5.0 for STM32WB Discovery, 63/384 KiB RAM/FLASH dictionary (C) 2022 peter@spyr.ch * Firmware Package STM32Cube FW_WB V1.14.1, USB-CDC, BLE Stack 5.3 (C) 2022 STMicroelectronics
  * CMSIS-RTOS V2 FreeRTOS wrapper, FreeRTOS Kernel V10.3.1 (C) 2020 Amazon.com * FatFs for internal flash and microSD - Generic FAT fs module R0.12c (C) 2017 ChaN * tiny vi - part of BusyBox (C) 2000, 2001 Sterling Huxley

Revision 122022-11-05 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 14 to 14
  Sources on GitHub (WB5M branch on Mecrisp-Cube)
Changed:
<
<
>
>
 
Line: 236 to 236
 Creative Commons License
This work by Peter Schmid is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

META FILEATTACHMENT attachment="wbfeather.jpg" attr="" comment="" date="1625171894" name="wbfeather.jpg" path="wbfeather.jpg" size="714220" user="PeterSchmid" version="1"
Added:
>
>
META FILEATTACHMENT attachment="discovery.jpg" attr="" comment="" date="1667651257" name="discovery.jpg" path="discovery.jpg" size="443355" user="PeterSchmid" version="1"

Revision 112022-10-11 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 52 to 52
 

Getting Started

These instructions will get you a copy of the project up and running on your local

Changed:
<
<
machine (STM32WB5MM-DK Dscovery Kit) for development and testing purposes.
>
>
machine (STM32WB5MM-DK Discovery Kit) for development and testing purposes.
 

Prerequisites

Revision 102022-10-10 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 56 to 56
 

Prerequisites

Changed:
<
<
  • STM32WB5MM-DK Dscovery Kit with STM32W5MMG module, STM32WB55 MCU (Cortex ARM M4) runs at a 32 MHz (the Bluetooth stack runs on a Cortex ARM M0+ core). ST-Link debugger/programmer is integrated on board.
>
>
  • STM32WB5MM-DK Dscovery Kit with STM32W5MMG module, STM32WB55 MCU (Cortex ARM M4) runs at a 32 MHz (the Bluetooth stack runs on a Cortex ARM M0+ core). ST-Link debugger/programmer is integrated on board.
 
  • Terminal emulator application for PC, e.g.:

Revision 92022-10-05 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 15 to 15
 Sources on GitHub (WB5M branch on Mecrisp-Cube)

Added:
>
>
 

Revision 82022-10-02 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 19 to 19
 
Changed:
<
<
>
>
 

Features

The standard Mecrisp-Cube features like RTOS, Filesystem, USB, etc.

  • 63 KiB RAM dictionary
Changed:
<
<
  • 368 KiB Flash dictionary
  • Internal Serial Flash drive 0:, 1 MiB
  • microSD drive 1: (external adapter)
>
>
 
  • OLED display 128x64 pixel
  • RGB LED
Line: 47 to 47
 

Getting Started

These instructions will get you a copy of the project up and running on your local

Changed:
<
<
machine (STM32WB Feather Developer Board) for development and testing purposes.
>
>
machine (STM32WB5MM-DK Dscovery Kit) for development and testing purposes.
 

Prerequisites

Changed:
<
<
  • STM32WB Feather Development Board Stackable Feather board with STM32WB55 MCU (Cortex ARM M4) runs at a 32 MHz (the Bluetooth stack runs on a Cortex ARM M0+ core). If you want to debug C and assembler programs you need an ST-Link debugger/programmer.
>
>
  • STM32WB5MM-DK Dscovery Kit with STM32W5MMG module, STM32WB55 MCU (Cortex ARM M4) runs at a 32 MHz (the Bluetooth stack runs on a Cortex ARM M0+ core). ST-Link debugger/programmer is integrated on board.
 
  • Terminal emulator application for PC, e.g.:
Line: 61 to 61
  Flash the Mecrisp-Cube binary (MecrispCubeWB5M.bin) or the util-binary (MecrispCubeWB5MUtil.bin) to the Discovery Board.
Changed:
<
<
  1. Connect the Discovery Board USB to the PC
  2. Hold the USR button (BOOTP Pin), push the RES button, release the USR button
  3. Program the binary (MecrispCubeWB5M.bin or MecrispCubeWBfeatherUtil.bin) with the STMCubeProgrammer (select USB Device)
  4. Reset or power cycle the Feather board
>
>
  1. Connect the Discovery Board USB ST-LINK to the PC
  2. Copy the binary (MecrispCubeWB5M.bin or MecrispCubeWB5MUtil.bin) to the USB mass storage DIS_WB5MMG
  Start the terminal emulator application on the PC. Check for the serial communication port (e.g. for Linux /dev/ttyACM0).
Line: 80 to 78
 
Mecrisp-Stellaris RA 2.5.4 by Matthias Koch.

Changed:
<
<
Mecrisp-Cube 1.4.4 for STM32WB Feather, 63/384 KiB RAM/FLASH dictionary (C) 2021 peter@spyr.ch * Firmware Package STM32Cube FW_WB V1.11.0, USB-CDC, BLE Stack 5.0 (C) 2021 STMicroelectronics
>
>
Mecrisp-Cube 1.4.5 for STM32WB Discovery, 63/384 KiB RAM/FLASH dictionary (C) 2022 peter@spyr.ch * Firmware Package STM32Cube FW_WB V1.11.0, USB-CDC, BLE Stack 5.3 (C) 2022 STMicroelectronics
  * CMSIS-RTOS V2 FreeRTOS wrapper, FreeRTOS Kernel V10.3.1 (C) 2020 Amazon.com * FatFs for internal flash and microSD - Generic FAT fs module R0.12c (C) 2017 ChaN * tiny vi - part of BusyBox (C) 2000, 2001 Sterling Huxley
Line: 96 to 94
 USB-CDC is the default console.
Button 1
CRS (Bluetooth Cable Replacement Service) is standard console
Button 2
UART is standard console
Deleted:
<
<
Button 3
ignore /etc/rc.local
Button USR
start STM bootloader
red LED
the LED lights up during the initialization phase
 
Changed:
<
<

Neopixel as Status Indicator

The optional NeoPixel displays the status
>
>

RGB LED as Status Indicator

The RGB LED displays the status
 
dimmed Green
USB enumeration successfull
dimmed Blue
BLE connected
flashing Red
"disk" (serial flash or SD) write operation
Line: 109 to 104
 

Additional Tools and Local Filesystem

Changed:
<
<
Populate a microSD with the contents of sdcard. Put the microSD into the uSD Card slot and reset or power cycle the board.
>
>
Populate a microSD with the contents of sdcard. Put the microSD into the uSD Card slot and reset or power cycle the board.
  The directory should look like this:

Line: 126 to 121
 You can use the local CLI commands like mkfs, mkdir and cp to create a filesystem on the serial flash and fill it with files and folders. But this is tedious job because I haven't yet implemented a recursive copy for MecrispCube. But there is prepared disk image (for details see MicroSdBlocks#Serial_Flash) on microSD and the tool dd. You can copy the disk image to the drive 0: (this takes about 8 Minutes):

Changed:
<
<
dd 1:/boot/fd-16MiB.img 0:[CR]
>
>
dd 1:/boot/fd-1MiB.img 0:[CR]
  ok. mount 0:[CR] ok.
Line: 136 to 131
  ok.
Changed:
<
<
The Mecrisp have some tools bundled in its distribution e.g. assembler, disassembler, dump, float. I put those tools and some more into the folder /fsr. With the "init.fs script" I compile my favorite ones into the flash directory (if you use the util-binary binary, these tools are already compiled in):
>
>
The Mecrisp have some tools bundled in its distribution e.g. assembler, disassembler, dump, float. I put those tools and some more into the folder /fsr. With the "init.fs script" I compile my favorite ones into the flash directory (if you use the util-binary binary, these tools are already compiled in):
 
compiletoflash[CR]  ok.
include /etc/init.fs[CR]

Line: 170 to 165
 08040608: F847 str r6 [ r7 #-4 ]!
Added:
>
>

 
Changed:
<
<

Installing

>
>

Installing Development Environment

  A step by step series of examples that tell you how to get a development env running
Line: 184 to 182
 Get the sources from github:


Changed:
<
<
psi@homer:~> git clone --branch WBfeather https://github.com/spyren/Mecrisp-Cube
>
>
psi@homer:~> git clone --branch WB5M https://github.com/spyren/Mecrisp-Cube
 Klone nach 'Mecrisp-Cube' ... remote: Enumerating objects: 1157, done. remote: Counting objects: 100% (1157/1157), done.

Revision 72022-10-01 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 25 to 25
 The standard Mecrisp-Cube features like RTOS, Filesystem, USB, etc.

  • 63 KiB RAM dictionary
Changed:
<
<
  • 128 KiB Flash dictionary
  • Internal Serial Flash drive 0:, 384 KiB
>
>
  • 368 KiB Flash dictionary
  • Internal Serial Flash drive 0:, 1 MiB
 
  • microSD drive 1: (external adapter)
  • OLED display 128x64 pixel
  • RGB LED

Revision 62022-09-29 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Changed:
<
<
image="/twiki/pub/MecrispCube/BoardSupportPackageWBfeather/WB_Feather_header.jpg" title="!MecrispCube for the STM32WB Feather Developer Board"
>
>
image="/twiki/pub/MecrispCube/BoardSupportPackageWB5M/wb55-discovery-header.jpg" title="Mecrisp-Cube for the STM32WB5MM-DK Discovery Board"
  titlestyle="color:#F00000;" }%
Intro
Changed:
<
<
After discovering Adafruit's Feather STM32F405 for myself, I wanted to develop a Feather board for the STM32WB. Luckily I found the STM32WB Feather Development Board from Reclaimer Labs. This board has everything I need.
>
>
The STM32WB5MM-DK Discovery Board is not as cheep as the Nucleo Board but it has plenty of peripherals on board: OLED display 128x64 pixel, 128-Mbit Quad-SPI NOR Flash Memory, temperature sensor, accelerometer/gyroscope sensor, Time‑of‑Flight and gesture‑detection sensor, digital microphone, RGB LED, infrared LED, and touch sensor.
  Instant real-time programming with Forth.
Changed:
<
<
Sources on GitHub (WBfeather branch on Mecrisp-Cube)
>
>
Sources on GitHub (WB5M branch on Mecrisp-Cube)
 
Changed:
<
<
>
>
 
Line: 21 to 22
 

Features

Changed:
<
<
  • 61 KiB RAM dictionary
  • 384 KiB Flash dictionary
  • Forth as CMSIS-RTOS thread. CMSIS-RTOS API to use FreeRTOS within Forth.
  • Buffered terminal I/O (5 KiB buffer for UART Rx). Interrupt driven and RTOS aware, key and emit block the calling thread. USART1: D0 RX, D1 TX
  • USB-CDC for serial communication via USB. Redirect console I/O like cdc-emit, cdc-key
  • microSD and internal serial Flash mass storage for blocks and FAT filesystem.
  • Digital and analog pins
    • LEDs: LED1 (red) D12
    • Digital port pins: D0 to D15 (without D7 and D8)
    • Analog port pins: A0 to A5
    • PWM: TIM1CH1 A4, TIM1CH2 D1, TIM1CH3 D0
    • Input capture TIM2CH1 A5
    • Output compare TIM2CH2 D13, TIM2CH3 D5, TIM2CH4 D6
    • EXTI: D5, D6, D11, D13
  • UART: D0 RX, D1 TX
  • SPI: D2 SCK, D3 MISO, D4 MOSI (e.g. for display, memory)
  • I2C: D14 SDA, D15 SCL (external peripherals e.g. pressure sensor)
  • vi Editor origin in BusyBox tiny vi. Workflow development: begin Edit EVALUATE while SaveFile repeat
  • Real Time Clock (32 bit UNIX time stamp, valid times are from 1.1.2000 to 31.12.2099 because of the STM32WB RTC peripheral) time!, time@, and .time (YYYY-MM-DDTHH:MM:SS ISO 8601).

>
>
The standard Mecrisp-Cube features like RTOS, Filesystem, USB, etc.
 
Changed:
<
<
>
>
  • 63 KiB RAM dictionary
  • 128 KiB Flash dictionary
  • Internal Serial Flash drive 0:, 384 KiB
  • microSD drive 1: (external adapter)
  • OLED display 128x64 pixel
  • RGB LED

Not supported yet:

  • temperature sensor
  • accelerometer/gyroscope sensor
  • Time-of-Flight and gesture/detection sensor
  • digital microphone
  • infrared LED
  • touch sensor
 
Changed:
<
<
For more BSP details see BoardSupportPackageWBfeather.
>
>
For more BSP details see BoardSupportPackageWB5M.
 
Line: 75 to 59
 
    • minicom, microcom, screen - Linux
    • Use the built in Eclipse console (but no LF)

Changed:
<
<
Flash the Mecrisp-Cube binary (MecrispCubeWBfeather.bin) or the util-binary (MecrispCubeWBfeatherUtil.bin) to the Feather Board.
>
>
Flash the Mecrisp-Cube binary (MecrispCubeWB5M.bin) or the util-binary (MecrispCubeWB5MUtil.bin) to the Discovery Board.
 
Changed:
<
<
  1. Connect the Feather Board USB to the PC
>
>
  1. Connect the Discovery Board USB to the PC
 
  1. Hold the USR button (BOOTP Pin), push the RES button, release the USR button
Changed:
<
<
  1. Program the binary (MecrispCubeWBfeather.bin or MecrispCubeWBfeatherUtil.bin) with the STMCubeProgrammer (select USB Device)
>
>
  1. Program the binary (MecrispCubeWB5M.bin or MecrispCubeWBfeatherUtil.bin) with the STMCubeProgrammer (select USB Device)
 
  1. Reset or power cycle the Feather board

Start the terminal emulator application on the PC.

Line: 218 to 202
 Browse to Mecrisp-Cube directory
Changed:
<
<
Generate code from the STM32CubeMX MecrispCubeWBfeather.ioc file:
>
>
Generate code from the STM32CubeMX MecrispCubeWB5M.ioc file:
 
Project -> Generate Code 

Revision 52021-07-05 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 112 to 112
 USB-CDC is the default console.
Button 1
CRS (Bluetooth Cable Replacement Service) is standard console
Button 2
UART is standard console
Changed:
<
<
Button 3
ignore /etc/rc.local
>
>
Button 3
ignore /etc/rc.local
 
Button USR
start STM bootloader
red LED
the LED lights up during the initialization phase

Revision 42021-07-05 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 7 to 7
  titlestyle="color:#F00000;" }%
Intro
Added:
>
>
After discovering Adafruit's Feather STM32F405 for myself, I wanted to develop a Feather board for the STM32WB. Luckily I found the STM32WB Feather Development Board from Reclaimer Labs. This board has everything I need.
  Instant real-time programming with Forth.
Line: 22 to 23
 
  • 61 KiB RAM dictionary
  • 384 KiB Flash dictionary
Changed:
<
<
  • Forth as CMSIS-RTOS thread. CMSIS-RTOS API to use FreeRTOS from Forth.
  • Buffered terminal I/O (5 KiB buffer for UART Rx). Interrupt driven and RTOS aware, key and emit block the calling thread. USART3: D0 RX, D1 TX
>
>
  • Forth as CMSIS-RTOS thread. CMSIS-RTOS API to use FreeRTOS within Forth.
  • Buffered terminal I/O (5 KiB buffer for UART Rx). Interrupt driven and RTOS aware, key and emit block the calling thread. USART1: D0 RX, D1 TX
 
  • USB-CDC for serial communication via USB. Redirect console I/O like cdc-emit, cdc-key
Changed:
<
<
>
>
 
    • Internal Flash drive 0:, 16 MiB serial Flash W25Q128
    • microSD drive 1: (needs adaptor)
    • Filesystem API
Line: 40 to 41
 
    • EXTI: D5, D6, D11, D13
  • UART: D0 RX, D1 TX
  • SPI: D2 SCK, D3 MISO, D4 MOSI (e.g. for display, memory)
Changed:
<
<
  • I2C: D14 SDA, D15 SCL (external peripherals e.g. pressure)
>
>
  • I2C: D14 SDA, D15 SCL (external peripherals e.g. pressure sensor)
 
  • vi Editor origin in BusyBox tiny vi. Workflow development: begin Edit EVALUATE while SaveFile repeat
  • Real Time Clock (32 bit UNIX time stamp, valid times are from 1.1.2000 to 31.12.2099 because of the STM32WB RTC peripheral) time!, time@, and .time (YYYY-MM-DDTHH:MM:SS ISO 8601).
Line: 62 to 63
 

Getting Started

These instructions will get you a copy of the project up and running on your local

Changed:
<
<
machine (STM32WB Feather Developer Board) for development and testing purposes.
>
>
machine (STM32WB Feather Developer Board) for development and testing purposes.
 

Prerequisites

Revision 32021-07-02 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 20 to 20
 

Features

Added:
>
>
  • 61 KiB RAM dictionary
  • 384 KiB Flash dictionary
  • Forth as CMSIS-RTOS thread. CMSIS-RTOS API to use FreeRTOS from Forth.
  • Buffered terminal I/O (5 KiB buffer for UART Rx). Interrupt driven and RTOS aware, key and emit block the calling thread. USART3: D0 RX, D1 TX
  • USB-CDC for serial communication via USB. Redirect console I/O like cdc-emit, cdc-key
  • microSD and internal Flash mass storage for blocks and FAT filesystem.
  • Digital and analog pins
    • LEDs: LED1 (red) D12
    • Digital port pins: D0 to D15 (without D7 and D8)
    • Analog port pins: A0 to A5
    • PWM: TIM1CH1 A4, TIM1CH2 D1, TIM1CH3 D0
    • Input capture TIM2CH1 A5
    • Output compare TIM2CH2 D13, TIM2CH3 D5, TIM2CH4 D6
    • EXTI: D5, D6, D11, D13
  • UART: D0 RX, D1 TX
  • SPI: D2 SCK, D3 MISO, D4 MOSI (e.g. for display, memory)
  • I2C: D14 SDA, D15 SCL (external peripherals e.g. pressure)
  • vi Editor origin in BusyBox tiny vi. Workflow development: begin Edit EVALUATE while SaveFile repeat
  • Real Time Clock (32 bit UNIX time stamp, valid times are from 1.1.2000 to 31.12.2099 because of the STM32WB RTC peripheral) time!, time@, and .time (YYYY-MM-DDTHH:MM:SS ISO 8601).

For more BSP details see BoardSupportPackageWBfeather.

 

Line: 59 to 95
 
Mecrisp-Stellaris RA 2.5.4 by Matthias Koch.

Changed:
<
<
Mecrisp-Cube 1.4.3 for STM32F405, 31/768 KiB RAM/FLASH dictionary (C) 2021 peter@spyr.ch * Firmware Package STM32Cube F4 V1.26.0, USB-CDC (C) 2021 STMicroelectronics
>
>
Mecrisp-Cube 1.4.4 for STM32WB Feather, 63/384 KiB RAM/FLASH dictionary (C) 2021 peter@spyr.ch * Firmware Package STM32Cube FW_WB V1.11.0, USB-CDC, BLE Stack 5.0 (C) 2021 STMicroelectronics
  * CMSIS-RTOS V2 FreeRTOS wrapper, FreeRTOS Kernel V10.3.1 (C) 2020 Amazon.com
Changed:
<
<
* FatFs for serial flash and microSD - Generic FAT fs module R0.12c (C) 2017 ChaN
>
>
* FatFs for internal flash and microSD - Generic FAT fs module R0.12c (C) 2017 ChaN
  * tiny vi - part of BusyBox (C) 2000, 2001 Sterling Huxley

include 0:/etc/rc.local

Line: 66 to 102
  * tiny vi - part of BusyBox (C) 2000, 2001 Sterling Huxley

include 0:/etc/rc.local

Deleted:
<
<
 23 5 / .[CR] 4 ok. : hello ." World" ;[CR] ok. hello[CR] World ok.
Added:
>
>

Special Functions on Startup

USB-CDC is the default console.
Button 1
CRS (Bluetooth Cable Replacement Service) is standard console
Button 2
UART is standard console
Button 3
ignore /etc/rc.local
Button USR
start STM bootloader
red LED
the LED lights up during the initialization phase

Neopixel as Status Indicator

The optional NeoPixel displays the status
dimmed Green
USB enumeration successfull
dimmed Blue
BLE connected
flashing Red
"disk" (serial flash or SD) write operation
flashing Yellow
"disk" (serial flash or SD) read operation
 

Additional Tools and Local Filesystem

Populate a microSD with the contents of sdcard. Put the microSD into the uSD Card slot and reset or power cycle the board.
Line: 189 to 239
 
Deleted:
<
<
 

Revision 22021-07-02 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner" image="/twiki/pub/MecrispCube/BoardSupportPackageWBfeather/WB_Feather_header.jpg"
Changed:
<
<
title="!MecrispCube for the STM32WB Feather Developer Board"
>
>
title="!MecrispCube for the STM32WB Feather Developer Board"
  titlestyle="color:#F00000;" }%
Intro
Line: 26 to 26
 

Getting Started

These instructions will get you a copy of the project up and running on your local

Changed:
<
<
machine (Adafruit Feather STM32F405 Express board) for development and testing purposes.
>
>
machine (STM32WB Feather Developer Board) for development and testing purposes.
 

Prerequisites

Changed:
<
<
  • Adafruit Feather STM32F405 Stackable Feather board with STM32F405 MCU runs at a blistering 168 MHz. If you want to debug C and assembler programs you need an ST-Link debugger/programmer.
>
>
  • STM32WB Feather Development Board Stackable Feather board with STM32WB55 MCU (Cortex ARM M4) runs at a 32 MHz (the Bluetooth stack runs on a Cortex ARM M0+ core). If you want to debug C and assembler programs you need an ST-Link debugger/programmer.
 
  • Terminal emulator application for PC, e.g.:
Line: 38 to 38
 
    • minicom, microcom, screen - Linux
    • Use the built in Eclipse console (but no LF)

Changed:
<
<
Flash the Mecrisp-Cube binary (MecrispCubeF405.bin) or the util-binary (MecrispCubeF405Util.bin) to the Feather Board.
>
>
Flash the Mecrisp-Cube binary (MecrispCubeWBfeather.bin) or the util-binary (MecrispCubeWBfeatherUtil.bin) to the Feather Board.
 
Changed:
<
<
  1. Connect the BOOTP (BO Pin) to 3.3V
  2. Connect the Feather Board USB to the PC
  3. Program the binary with the STMCubeProgrammer
  4. Disconnect the BOOTP (BO Pin)
  5. Reset or power cycle the Feather board
>
>
  1. Connect the Feather Board USB to the PC
  2. Hold the USR button (BOOTP Pin), push the RES button, release the USR button
  3. Program the binary (MecrispCubeWBfeather.bin or MecrispCubeWBfeatherUtil.bin) with the STMCubeProgrammer (select USB Device)
  4. Reset or power cycle the Feather board
  Start the terminal emulator application on the PC. Check for the serial communication port (e.g. for Linux /dev/ttyACM0).
Line: 75 to 74
 

Additional Tools and Local Filesystem

Changed:
<
<
Populate a microSD with the contents of sdcard. Put the microSD into the F405 slot and reset or power cycle the board.
>
>
Populate a microSD with the contents of sdcard. Put the microSD into the uSD Card slot and reset or power cycle the board.
  The directory should look like this:

Line: 90 to 89
 

You can use the local CLI commands like mkfs, mkdir and cp to create a filesystem on the serial flash and fill it with files and folders. But this is tedious job because I haven't yet implemented a recursive copy for MecrispCube. But there is prepared disk image

Changed:
<
<
(for details see MicroSdBlocks#Serial_Flash) on microSD and the tool dd. You can copy the disk image to the drive 0: (this takes about 2 Minutes):
>
>
(for details see MicroSdBlocks#Serial_Flash) on microSD and the tool dd. You can copy the disk image to the drive 0: (this takes about 8 Minutes):
 

Changed:
<
<
dd 1:/boot/fd-2MiB.img 0:[CR]
>
>
dd 1:/boot/fd-16MiB.img 0:[CR]
  ok. mount 0:[CR] ok.
Line: 102 to 101
  ok.
Changed:
<
<
The Mecrisp have some tools bundled in its distribution e.g. assembler, disassembler, dump, float. I put those tools and some more into the folder /fsr. With the "init.fs script" I compile my favorite ones into the flash directory:
>
>
The Mecrisp have some tools bundled in its distribution e.g. assembler, disassembler, dump, float. I put those tools and some more into the folder /fsr. With the "init.fs script" I compile my favorite ones into the flash directory (if you use the util-binary binary, these tools are already compiled in):
 
compiletoflash[CR]  ok.
include /etc/init.fs[CR]

Line: 150 to 149
 Get the sources from github:


Changed:
<
<
psi@homer:~> git clone --branch F405 https://github.com/spyren/Mecrisp-Cube
>
>
psi@homer:~> git clone --branch WBfeather https://github.com/spyren/Mecrisp-Cube
 Klone nach 'Mecrisp-Cube' ... remote: Enumerating objects: 1157, done. remote: Counting objects: 100% (1157/1157), done.
Line: 168 to 167
 Browse to Mecrisp-Cube directory
Changed:
<
<
Generate code from the STM32CubeMX MecrispCubeF405.ioc file:
>
>
Generate code from the STM32CubeMX MecrispCubeWBfeather.ioc file:
 
Project -> Generate Code 

Revision 12021-07-01 - PeterSchmid

Line: 1 to 1
Added:
>
>
META TOPICPARENT name="WebHome"
MecrispCube for the STM32WB Feather Developer Board
Intro

Instant real-time programming with Forth.

Sources on GitHub (WBfeather branch on Mecrisp-Cube)

Features

Getting Started

These instructions will get you a copy of the project up and running on your local machine (Adafruit Feather STM32F405 Express board) for development and testing purposes.

Prerequisites

  • Adafruit Feather STM32F405 Stackable Feather board with STM32F405 MCU runs at a blistering 168 MHz. If you want to debug C and assembler programs you need an ST-Link debugger/programmer.
  • Terminal emulator application for PC, e.g.:
    • PuTTY - Windows and Linux
    • Tera Term - Windows
    • Realterm - Windows
    • minicom, microcom, screen - Linux
    • Use the built in Eclipse console (but no LF)

Flash the Mecrisp-Cube binary (MecrispCubeF405.bin) or the util-binary (MecrispCubeF405Util.bin) to the Feather Board.

  1. Connect the BOOTP (BO Pin) to 3.3V
  2. Connect the Feather Board USB to the PC
  3. Program the binary with the STMCubeProgrammer
  4. Disconnect the BOOTP (BO Pin)
  5. Reset or power cycle the Feather board

Start the terminal emulator application on the PC. Check for the serial communication port (e.g. for Linux /dev/ttyACM0). I set the putty terminal configuration to

  • Implicit CR in every LF
  • Local echo: Auto
  • Local line editing: Auto
  • Keyboard Backspace: Control-H
  • Keyboard Function: Keys VT100
  • Remote character set: CP850

Mecrisp-Stellaris RA 2.5.4 by Matthias Koch.

Mecrisp-Cube 1.4.3 for STM32F405, 31/768 KiB RAM/FLASH dictionary (C) 2021 peter@spyr.ch
  * Firmware Package STM32Cube F4 V1.26.0, USB-CDC (C) 2021 STMicroelectronics
  * CMSIS-RTOS V2 FreeRTOS wrapper, FreeRTOS Kernel V10.3.1 (C) 2020 Amazon.com
  * FatFs for serial flash and microSD - Generic FAT fs module  R0.12c (C) 2017 ChaN
  * tiny vi - part of BusyBox (C) 2000, 2001 Sterling Huxley

include 0:/etc/rc.local

23 5 / .[CR] 4  ok.
: hello ." World" ;[CR]  ok.
hello[CR] World ok.

Additional Tools and Local Filesystem

Populate a microSD with the contents of sdcard. Put the microSD into the F405 slot and reset or power cycle the board.

The directory should look like this:

ls -l 1:[CR]
drw-         0 2021-04-18T18:12:38 boot
drw-         0 2021-03-21T18:47:52 etc
drw-         0 2021-03-21T18:47:54 fsr
drw-         0 2021-03-21T18:47:54 home
drw-         0 2021-03-21T18:47:56 man
-rwa      7219 2021-01-08T19:42:36 README.md
ok.

You can use the local CLI commands like mkfs, mkdir and cp to create a filesystem on the serial flash and fill it with files and folders. But this is tedious job because I haven't yet implemented a recursive copy for MecrispCube. But there is prepared disk image (for details see MicroSdBlocks#Serial_Flash) on microSD and the tool dd. You can copy the disk image to the drive 0: (this takes about 2 Minutes):

dd 1:/boot/fd-2MiB.img 0:[CR]
 ok.
mount 0:[CR]
 ok.
ls 0:[CR]
man                     fsr                     README.md               boot
etc                     home
 ok.

The Mecrisp have some tools bundled in its distribution e.g. assembler, disassembler, dump, float. I put those tools and some more into the folder /fsr. With the "init.fs script" I compile my favorite ones into the flash directory:

compiletoflash[CR]  ok.
include /etc/init.fs[CR]
init.fs Loading started
RAM Dictionary: 392991 KiB
utils.fs loading ...
conditional.fs loading ...
dump.fs loading ...
disassembler-m3.fs loading ...
float.fs loading ...
threads.fs loading ...
RAM Dictionary: 392981 KiB
init.fs finished  ok.

For example, the word disassember is available now:

see dump[CR]
080405F0: B500  push { lr }
080405F2: F7C2  bl  08002A3E  --> cr
080405F4: FA24
080405F6: CF08  ldmia r7 { r3 }
080405F8: F013  ands r2 r3 #F
080405FA: 020F
080405FC: F847  str r3 [ r7 #-4 ]!
080405FE: 3D04
08040600: 2A00  cmp r2 #0
08040602: D000  beq 08040606
08040604: 3610  adds r6 #10
08040606: CF08  ldmia r7 { r3 }
08040608: F847  str r6 [ r7 #-4 ]!

Installing

A step by step series of examples that tell you how to get a development env running

Install the IDE STM32CubeIDE, it is Eclipse and GCC based. STM32CubeMX is included in the IDE, you need a stand alone installation only if you do not want to use the STM32CubeIDE.

Get the sources from github:

psi@homer:~> git clone --branch F405 https://github.com/spyren/Mecrisp-Cube
Klone nach 'Mecrisp-Cube' ...
remote: Enumerating objects: 1157, done.
remote: Counting objects: 100% (1157/1157), done.
remote: Compressing objects: 100% (620/620), done.
remote: Total 3183 (delta 720), reused 934 (delta 525), pack-reused 2026
Empfange Objekte: 100% (3183/3183), 41.60 MiB | 6.96 MiB/s, Fertig.
Löse Unterschiede auf: 100% (2100/2100), Fertig.

Import the project into the IDE:

File -> Import -> General -> Existing Projects into Workspace -> Select root directory
Copy project into workspace
Browse to Mecrisp-Cube directory

Generate code from the STM32CubeMX MecrispCubeF405.ioc file:

Project -> Generate Code 

Restore changed source files

$ git status
{list of changed files}
$ git restore {files to restore} 

Select the Build Configuration (Debug if you want to debug the project) and Build the project:

Project -> Build Configurations -> Set Active -> Debug/Release 
Project -> Build Project

-- Peter Schmid - 2021-07-01

Creative Commons License
This work by Peter Schmid is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

META FILEATTACHMENT attachment="wbfeather.jpg" attr="" comment="" date="1625171894" name="wbfeather.jpg" path="wbfeather.jpg" size="714220" user="PeterSchmid" version="1"
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback