Difference: MecrispCubeFlipper (1 vs. 20)

Revision 202023-12-31 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 12 to 12
 The Flipper Zero is an excellent portable tool for interaction with access control systems. But the display, the buttons, LIPO (2.1 Ah), GPIO, BLE, SD-Card, RTC, etc. make it also an ideal tool for programming on the go.
Changed:
<
<
Sources on GitHub (Flipper branch on Mecrisp-Cube)
>
>
This page is no longer updated regularly, the current documentation can be found at GitHub (Flipper branch on Mecrisp-Cube). Sources are also there.
 

Revision 192023-12-14 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 8 to 8
 }%
Intro

Deleted:
<
<
 Instant real-time programming with Forth.
Added:
>
>
The Flipper Zero is an excellent portable tool for interaction with access control systems. But the display, the buttons, LIPO (2.1 Ah), GPIO, BLE, SD-Card, RTC, etc. make it also an ideal tool for programming on the go.
  Sources on GitHub (Flipper branch on Mecrisp-Cube)

Deleted:
<
<
 
Contents
Line: 89 to 87
 
Switch Off
press and hold the BACK-Button for 5 s or type in the command halt
Switch On
press the BACK-Button
Added:
>
>
Reset
press and hold the BACK- and LEFT-Button
 

Special Functions on Startup

Revision 182023-12-13 - PeterSchmid

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

Flash the Mecrisp-Cube Firmware

Changed:
<
<
Flash the Mecrisp-Cube binary (MecrispCubeFlipper.bin) or better the fs-util-binary (MecrispCubeFlipperFS.bin) to the Flipper Zero. Using the built-in USB DFU bootloader, see also firmware recovery.
>
>
Flash the Mecrisp-Cube binary (MecrispCubeFlipper.bin) or better the fs-util-binary (MecrispCubeFlipperFS.bin) to the Flipper Zero. Using the built-in USB DFU bootloader, see also firmware recovery.
 
  1. Press and hold the OK and the back buttons for 30 s (you should see a blank screen)
  2. Connect the Flipper Zero USB to the PC

Revision 172023-12-13 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 69 to 69
 
    • Realterm - Windows
    • minicom, microcom, screen - Linux
    • Use the built in Eclipse console (but no LF)
Added:
>
>
 

Flash the Mecrisp-Cube Firmware

Revision 162023-12-12 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 160 to 160
 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-1MiB.img 0:[CR]
>
>
dd 1:/boot/fd-384KiB.img 0:[CR]
  ok. mount 0:[CR] ok.

Revision 152023-12-11 - PeterSchmid

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

Features

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

Line: 53 to 53
 
Changed:
<
<
>
>
 

Getting Started

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

Line: 215 to 215
 
Changed:
<
<
>
>
 

Installing Development Environment

Revision 142023-12-11 - PeterSchmid

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

Flash the Mecrisp-Cube Firmware

Changed:
<
<
Flash the Mecrisp-Cube binary (MecrispCubeFlipper.bin) or the util-binary (MecrispCubeFlipperUtil.bin) to the Flipper Zero. Using the built-in USB DFU bootloader, see also firmware recovery.
>
>
Flash the Mecrisp-Cube binary (MecrispCubeFlipper.bin) or better the fs-util-binary (MecrispCubeFlipperFS.bin) to the Flipper Zero. Using the built-in USB DFU bootloader, see also firmware recovery.
 
  1. Press and hold the OK and the back buttons for 30 s (you should see a blank screen)
  2. Connect the Flipper Zero USB to the PC
Line: 98 to 98
 

RGB LED as Status Indicator

The RGB LED displays the status
Changed:
<
<
dimmed Green
USB enumeration successfull
>
>
dimmed Green
LIPO fully charged
dimmed Red
LIPO charging
 
dimmed Blue
BLE connected
flashing Red
"disk" (serial flash or SD) write operation
flashing Yellow
"disk" (serial flash or SD) read operation
Line: 142 to 143
 

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: 169 to 170
  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 fs-util-binary binary, these tools are already compiled in):
 
compiletoflash[CR]  ok.
include /etc/init.fs[CR]

Line: 229 to 230
 Get the sources from github:


Changed:
<
<
psi@homer:~> git clone --branch WB5M https://github.com/spyren/Mecrisp-Cube
>
>
psi@homer:~> git clone --branch Flipper https://github.com/spyren/Mecrisp-Cube
 Klone nach 'Mecrisp-Cube' ... remote: Enumerating objects: 1157, done. remote: Counting objects: 100% (1157/1157), done.
Line: 247 to 248
 Browse to Mecrisp-Cube directory
Changed:
<
<
Generate code from the STM32CubeMX MecrispCubeWB5M.ioc file:
>
>
Generate code from the STM32CubeMX MecrispCubeFlipper.ioc file:
 
Project -> Generate Code 

Revision 132023-12-10 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 84 to 84
 
  1. Reboot your device by pressing and holding the left and back buttons
Changed:
<
<

Switch On/Off

>
>

Switch On/Off, Buttons, LED

 
Switch Off
press and hold the BACK-Button for 5 s or type in the command halt
Switch On
press the BACK-Button
Added:
>
>

Special Functions on Startup

USB-CDC is the default console.
Button UP
CRS (Bluetooth Cable Replacement Service) is standard console
Button DOWN
UART is standard console
Button RIGHT
do not include 0:/etc/rc.local

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
flashing Yellow
"disk" (serial flash or SD) read operation
 

Use the Terminal (USB CDC)

Line: 127 to 140
 hello[CR] World ok.
Deleted:
<
<

Special Functions on Startup

USB-CDC is the default console.
Button UP
CRS (Bluetooth Cable Replacement Service) is standard console
Button DOWN
UART is standard console
Button RIGHT
do not include 0:/etc/rc.local

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
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.

Revision 122023-12-10 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 84 to 84
 
  1. Reboot your device by pressing and holding the left and back buttons
Added:
>
>

Switch On/Off

Switch Off
press and hold the BACK-Button for 5 s or type in the command halt
Switch On
press the BACK-Button

 

Use the Terminal (USB CDC)

Connect the Flipper Zero USB to the PC. Start the terminal emulator application on the PC.

Line: 121 to 129
 

Special Functions on Startup

USB-CDC is the default console.
Changed:
<
<
Button 1
CRS (Bluetooth Cable Replacement Service) is standard console
Button 2
UART is standard console
>
>
Button UP
CRS (Bluetooth Cable Replacement Service) is standard console
Button DOWN
UART is standard console
Button RIGHT
do not include 0:/etc/rc.local
 

RGB LED as Status Indicator

The RGB LED displays the status

Revision 112023-12-02 - PeterSchmid

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

Getting Started

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

Changed:
<
<
machine Flipper Zero for development and testing purposes.
>
>
machine (Flipper Zero) for development and testing purposes.
 

Prerequisites

Changed:
<
<
  • Flipper Zero with STM32WB55 MCU (Cortex ARM M4) runs at a 32 MHz (the Bluetooth stack runs on a Cortex ARM M0+ core). Optional ST-Link debugger/programmer.
>
>
 
  • Terminal emulator application for PC, e.g.:
Line: 70 to 71
 
    • Use the built in Eclipse console (but no LF)
  • STM32CubeProgrammer or qFlipper

Added:
>
>

Flash the Mecrisp-Cube Firmware

 Flash the Mecrisp-Cube binary (MecrispCubeFlipper.bin) or the util-binary (MecrispCubeFlipperUtil.bin) to the Flipper Zero. Using the built-in USB DFU bootloader, see also firmware recovery.

  1. Press and hold the OK and the back buttons for 30 s (you should see a blank screen)
Changed:
<
<
  1. Connect the Flipper Zero USB to the PC
  2. Program the binary (MecrispCubeFlipper.bin or MecrispCubeFlipperFS.bin) with the STMCubeProgrammer (select USB Device) for Linux sudo /usr/local/STMicroelectronics/STM32Cube/STM32CubeProgrammer/bin/STM32CubeProgrammer
  3. Reboot your device by pressing and holding the left and back buttons
>
>
  1. Connect the Flipper Zero USB to the PC
  2. Program the binary (MecrispCubeFlipper.bin or MecrispCubeFlipperFS.bin) with
    1. the STMCubeProgrammer (select USB Device), for Linux
      sudo /usr/local/STMicroelectronics/STM32Cube/STM32CubeProgrammer/bin/STM32CubeProgrammer
    2. or the qFlipper with install from file
  3. Reboot your device by pressing and holding the left and back buttons
 
Changed:
<
<
Start the terminal emulator application on the PC.
>
>

Use the Terminal (USB CDC)

Connect the Flipper Zero USB to the PC. 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
Line: 89 to 97
 
  • Keyboard Function: Keys VT100
  • Remote character set: CP850
Added:
>
>
You should see something like this in your terminal:
 

Changed:
<
<
reset Mecrisp-Stellaris RA 2.5.4 by Matthias Koch.
>
>
Mecrisp-Stellaris RA 2.5.4 by Matthias Koch.
  Mecrisp-Cube 1.5.0 for STM32WB Flipper, 63/128 KiB RAM/FLASH dictionary (C) 2023 peter@spyr.ch * Firmware Package STM32Cube FW_WB V1.17.3, USB-CDC, BLE Stack 5.3 (C) 2023 STMicroelectronics
Line: 96 to 105
  * Firmware Package STM32Cube FW_WB V1.17.3, USB-CDC, BLE Stack 5.3 (C) 2023 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
Deleted:
<
<
 include 0:/etc/rc.local
Added:
>
>

Use the interpreter:


 23 5 / .[CR] 4 ok.
Added:
>
>

Type in your first Forth program:


 : hello ." World" ;[CR] ok. hello[CR] World ok.
Line: 178 to 194
 08040608: F847 str r6 [ r7 #-4 ]!
Added:
>
>

Flash the original Flipper Firmware

If you want to go back to the original firmware, do the following

  1. Press and hold the OK and the back buttons for 30 s (you should see a blank screen)
  2. Connect the Flipper Zero USB to the PC
  3. Flash the Flipper firmware with qFlipper REPAIR
  4. Reboot your device by pressing and holding the left and back buttons
 

Revision 102023-12-02 - PeterSchmid

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

Getting Started

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

Changed:
<
<
machine Flipper Zero) for development and testing purposes.
>
>
machine Flipper Zero for development and testing purposes.
 

Prerequisites

Line: 68 to 68
 
    • Realterm - Windows
    • minicom, microcom, screen - Linux
    • Use the built in Eclipse console (but no LF)
Added:
>
>
 
Changed:
<
<
Flash the Mecrisp-Cube binary (MecrispCubeFlipper.bin) or the util-binary (MecrispCubeFlipperUtil.bin) to the Flipper Zero.
>
>
Flash the Mecrisp-Cube binary (MecrispCubeFlipper.bin) or the util-binary (MecrispCubeFlipperUtil.bin) to the Flipper Zero. Using the built-in USB DFU bootloader, see also firmware recovery.
 
Changed:
<
<
  1. Connect the Flipper Zero USB to the PC
  2. Hold the xx button (BOOTP Pin), push the nRST button, release the nRST button
>
>
  1. Press and hold the OK and the back buttons for 30 s (you should see a blank screen)
  2. Connect the Flipper Zero USB to the PC
 
  1. Program the binary (MecrispCubeFlipper.bin or MecrispCubeFlipperFS.bin) with the STMCubeProgrammer (select USB Device)
Changed:
<
<
  1. Reset or power cycle the Flipper Zero
>
>
for Linux sudo /usr/local/STMicroelectronics/STM32Cube/STM32CubeProgrammer/bin/STM32CubeProgrammer
  1. Reboot your device by pressing and holding the left and back buttons
  Start the terminal emulator application on the PC. Check for the serial communication port (e.g. for Linux /dev/ttyACM0).

Revision 92023-12-02 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Changed:
<
<
image="/twiki/pub/MecrispCube/BoardSupportPackageFlipper/flipper-header.jpg"
>
>
image="/twiki/pub/MecrispCube/MecrispCubeFlipper/flipper-header.jpg"
  title="Mecrisp-Cube for the Flipper Zero" titlestyle="color:#F00000;" }%
Line: 61 to 61
 

Prerequisites

Changed:
<
<
  • Flipper Zero with 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.
>
>
  • Flipper Zero with STM32WB55 MCU (Cortex ARM M4) runs at a 32 MHz (the Bluetooth stack runs on a Cortex ARM M0+ core). Optional ST-Link debugger/programmer.
 
  • Terminal emulator application for PC, e.g.:
Line: 242 to 242
 Creative Commons License
This work by Peter Schmid is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

Sitronix ST7567 \ No newline at end of file

Added:
>
>
META FILEATTACHMENT attachment="flipper-header.jpg" attr="" comment="" date="1701510166" name="flipper-header.jpg" path="flipper-header.jpg" size="48472" user="PeterSchmid" version="1"

Revision 82023-11-26 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 38 to 38
 
  • LCD display 128x64 pixel
  • RGB LED
  • Power (LIPO charger and fuel gauge)
Added:
>
>
  • Vibration Motor
 
  • GPIO

Not supported yet:

Line: 46 to 47
 
  • NFC
  • Infrared Transceiver
  • iButton
Changed:
<
<
  • Buzzer
  • Vibration Motor
>
>
  • Buzzer/Speaker
  For more BSP details see BoardSupportPackageFlipper.

Revision 72023-11-26 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 37 to 37
 
  • Control (5-button joystick, Back button, Reboot)
  • LCD display 128x64 pixel
  • RGB LED
Added:
>
>
  • Power (LIPO charger and fuel gauge)
 
  • GPIO

Not supported yet:

Deleted:
<
<
  • Power (LIPO charger)
 
  • Sub-1 GHz Transceiver
  • 125kHz RFID
  • NFC

Revision 62023-11-25 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 35 to 35
 
  • Serial console UART / USB CDC / BLE
  • microSD drive 1:
  • Control (5-button joystick, Back button, Reboot)
Added:
>
>
  • LCD display 128x64 pixel
  • RGB LED
 
  • GPIO

Not supported yet:

Deleted:
<
<
  • LCD display 128x64 pixel
 
  • Power (LIPO charger)
Deleted:
<
<
  • RGB LED
 
  • Sub-1 GHz Transceiver
  • 125kHz RFID
  • NFC

Revision 52023-11-19 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 35 to 35
 
  • Serial console UART / USB CDC / BLE
  • microSD drive 1:
  • Control (5-button joystick, Back button, Reboot)
Added:
>
>
  • GPIO
  Not supported yet:
  • LCD display 128x64 pixel
  • Power (LIPO charger)
Deleted:
<
<
  • GPIO
 
  • RGB LED
  • Sub-1 GHz Transceiver
  • 125kHz RFID

Revision 42023-11-13 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Line: 13 to 13
  Sources on GitHub (Flipper branch on Mecrisp-Cube)
Changed:
<
<
Error: Exception 420: no decode delegate for this image format `' @ error/constitute.c/ReadImage/575
>
>
 
Changed:
<
<
>
>
 
  • Flash Mecrisp-Cube application and Stack/FUS to the target
Line: 69 to 69
 
    • minicom, microcom, screen - Linux
    • Use the built in Eclipse console (but no LF)

Changed:
<
<
Flash the Mecrisp-Cube binary (MecrispCubeFlipper.bin) or the util-binary (MecrispCubeFlipperUtil.bin) to the Discovery Board.
>
>
Flash the Mecrisp-Cube binary (MecrispCubeFlipper.bin) or the util-binary (MecrispCubeFlipperUtil.bin) to the Flipper Zero.
 
  1. Connect the Flipper Zero USB to the PC
  2. Hold the xx button (BOOTP Pin), push the nRST button, release the nRST button
Line: 88 to 88
 
  • Remote character set: CP850


Changed:
<
<
Mecrisp-Stellaris RA 2.5.4 by Matthias Koch.
>
>
reset Mecrisp-Stellaris RA 2.5.4 by Matthias Koch.
 
Changed:
<
<
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
>
>
Mecrisp-Cube 1.5.0 for STM32WB Flipper, 63/128 KiB RAM/FLASH dictionary (C) 2023 peter@spyr.ch * Firmware Package STM32Cube FW_WB V1.17.3, USB-CDC, BLE Stack 5.3 (C) 2023 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
Deleted:
<
<
* tiny vi - part of BusyBox (C) 2000, 2001 Sterling Huxley
  include 0:/etc/rc.local 23 5 / .[CR] 4 ok.

Revision 32023-11-11 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
%DASHBOARD{ section="banner"
Changed:
<
<
image=""
>
>
image="/twiki/pub/MecrispCube/BoardSupportPackageFlipper/flipper-header.jpg"
  title="Mecrisp-Cube for the Flipper Zero" titlestyle="color:#F00000;" }%

Revision 22023-10-21 - PeterSchmid

Line: 1 to 1
 
META TOPICPARENT name="WebHome"
Changed:
<
<

Title

>
>
Mecrisp-Cube for the Flipper Zero
Intro
 
Deleted:
<
<
Article text.
 
Changed:
<
<
Sitronix ST7567
>
>
Instant real-time programming with Forth.

Sources on GitHub (Flipper branch on Mecrisp-Cube)

Error: Exception 420: no decode delegate for this image format `' @ error/constitute.c/ReadImage/575

Features

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

  • 63 KiB RAM dictionary
  • 128 KiB Flash Forth dictionary
  • 50 KiB for C code
  • Internal Flash drive 0:, 384 KiB (for details see Nucleo)
  • Serial console UART / USB CDC / BLE
  • microSD drive 1:
  • Control (5-button joystick, Back button, Reboot)

Not supported yet:

  • LCD display 128x64 pixel
  • Power (LIPO charger)
  • GPIO
  • RGB LED
  • Sub-1 GHz Transceiver
  • 125kHz RFID
  • NFC
  • Infrared Transceiver
  • iButton
  • Buzzer
  • Vibration Motor

For more BSP details see BoardSupportPackageFlipper.

Getting Started

These instructions will get you a copy of the project up and running on your local machine Flipper Zero) for development and testing purposes.

Prerequisites

  • Flipper Zero with 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.:
    • 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 (MecrispCubeFlipper.bin) or the util-binary (MecrispCubeFlipperUtil.bin) to the Discovery Board.

  1. Connect the Flipper Zero USB to the PC
  2. Hold the xx button (BOOTP Pin), push the nRST button, release the nRST button
  3. Program the binary (MecrispCubeFlipper.bin or MecrispCubeFlipperFS.bin) with the STMCubeProgrammer (select USB Device)
  4. Reset or power cycle the Flipper Zero

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.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

include 0:/etc/rc.local
23 5 / .[CR] 4  ok.
: hello ." World" ;[CR]  ok.
hello[CR] World ok.

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

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
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.

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 8 Minutes):

dd 1:/boot/fd-1MiB.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 (if you use the util-binary binary, these tools are already compiled in):

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 Development Environment

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 WB5M 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 MecrispCubeWB5M.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 - 2023-10-18
Changed:
<
<

Comments

>
>
Creative Commons License
This work by Peter Schmid is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
 
Changed:
<
<
<--/commentPlugin-->
>
>
Sitronix ST7567

Revision 12023-10-18 - PeterSchmid

Line: 1 to 1
Added:
>
>
META TOPICPARENT name="WebHome"

Title

Article text.

Sitronix ST7567

-- Peter Schmid - 2023-10-18

Comments

<--/commentPlugin-->
 
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