Feelix
  • Feelix Documentation
  • Getting started
    • Designing Effects
      • Torque Effects
      • Position Effects
      • Velocity Effects
      • Dependent/Independent Effects
    • Effect Library
    • Creating Collections
  • Create and edit
    • Edit tools
    • Effect Settings
    • Layers
    • Grid
    • Export
    • TensorFlow
  • Uploading files
    • Setting up STM32
    • Connect and Upload
    • Hardware Settings
    • Troubleshooting Feelix
  • Hardware support
    • Hardware
    • PCB pinout
    • Setup
    • Dependencies
    • FeelixEffect Docs
      • Setup
      • Motor control
      • Import Effects
      • I2C communication
      • Example codes
  • Downloads
    • Feelix Design Tool
    • Feelix Arduino Library
    • 3D Models
    • Old Library Releases
Powered by GitBook
On this page
  • Prepare
  • Option 1: Arduino IDE
  • Option 2: Visual Studio & Platform IO

Was this helpful?

  1. Uploading files

Setting up STM32

Follow the steps bellow to setup programming STM32 microcontrollers with the Arduino IDE (Option 1, top) or Visual Studio and Platform IO (Option 2, bottom).

PreviousTensorFlowNextConnect and Upload

Last updated 3 days ago

Was this helpful?

Prepare

Make sure the device is in BOOT mode when uploading with Arduino IDE / Platform IO ()

The RESET button on the STM32 micrcontroller needs to be pressed after switching between BOOT and RUN mode in order to read the change

Option 1: Arduino IDE

Installed Libaries and Boards Managers should match the version specified in the documentation below.

The USB Serial port does not have to be specified (having one specified should not cause any problems either).

The USB Serial port is only used for Serial Monitor, when the device is in RUN mode the USB Serial port will appear in the Arduino IDE (Tools > Port)

Press the RESET button when the device is not recognized by the computer

Option 2: Visual Studio & Platform IO

[env:genericSTM32F401RE]
platform = ststm32
board = genericSTM32F401RE
framework = arduino
upload_protocol = dfu
monitor_speed = 115200
;only for monitoring serial data 
;the monitor port name can be read when the device is in RUN mode
;monitor_port = COM3
board_build.mcu = stm32f401ret6
board_build.f_cpu = 84000000L
board_build.core = ststm32
build_flags = 
	-D PIO_FRAMEWORK_ARDUINO_ENABLE_CDC
	-D USBCON
	-D USBD_VID=0x0483
	-D USBD_PID=0x0003
	-D USB_MANUFACTURER="Unknown"
	-D USB_PRODUCT="\"GENERIC_F401RETX\""
	-D HAL_PCD_MODULE_ENABLED
lib_deps = askuric/Simple FOC@^2.3.4

Upload using the upload button in the Arduino IDE

The program should be running now, if not check out the

Press the RESET button when the device is not recognized by the computer. Check out the when issues persist.

troubleshoot page
troubleshoot page
STM32CubeProgrammer
Dependencies
see pinout diagram
your program
Additional Boards Manager URLs window
Boards Manager Arduino IDE
Arduino IDE Board Settings
Visual Studio Project Board Settings