User Tools

Site Tools


silf4ware

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
silf4ware [2020/04/28 19:32]
d7ab6ba3
silf4ware [2020/07/09 12:36] (current)
d7ab6ba3 [Gestures]
Line 4: Line 4:
   * [[https://github.com/markusgritsch/SilF4ware|Github Repository]]   * [[https://github.com/markusgritsch/SilF4ware|Github Repository]]
  
-===== Hardware =====+===== Supported Hardware =====
  
-==== Receiver ====+For wiring receiver modules, see [[:silf4ware-wiring|this page]].
  
-=== NRF24 ===+^Flight Controller^Weight^Notes^Board Pinout| 
 +|Omnibus|3.2g| |[[https://github.com/markusgritsch/SilF4ware/blob/master/Targets/STM32F405 Omnibus/board_pinout.jpg|Image]]| 
 +|NOXE (first version)|3.4g (?)| |[[https://github.com/markusgritsch/SilF4ware/blob/master/Targets/STM32F411 NOXE/board_pinout.jpg|Image]]| 
 +|NOXE v1|4.3g (?)|untested|[[https://github.com/markusgritsch/SilF4ware/blob/master/Targets/STM32F411 NOXE_V1/board_pinout.jpg|Image]]| 
 +|F4-XSD|4.2g|[[https://www.rcgroups.com/forums/showpost.php?p=44836165&postcount=994|RCGroups Post]]|[[https://github.com/markusgritsch/SilF4ware/blob/master/Targets/STM32F405 F4XSD/board_pinout.jpg|Image]]|
  
-The mini module is the lightest option (~0.5g) and is recommended for micro quadsThe module with PA+LNA (GT-24) provides a bigger range, but weight (~1.1g) and power consumption is higher.+^Receiver^Weight^Notes^Source| 
 +|NRF24 Mini|0.5g|[[https://www.rcgroups.com/forums/showpost.php?p=41923007&postcount=285|Howto add an wire antenna]]|use "nrf24l01 mini" as search term ([[https://www.banggood.com/NRF24L01-Mini-SMD-2_4GHz-Wireless-Module-Power-Enhanced-Version-SMD-Receiver-Transceiver-Low-Voltage-Oltage-Regulator-Board-5V-p-1495082.html|Banggood]])| 
 +|NRF24 PA LNA (GT-24)|1.1g|[[https://www.rcgroups.com/forums/showpost.php?p=42688011&postcount=640|Howto add an U.FL antenna]]|use "GT-24" as search term ([[https://www.banggood.com/GT-24-Digital-Wireless-Module-2_4G-NRF24L01-PA-LNA-Industrial-Grade-1100M-Long-Distance-With-Non-wel-p-1361350.html|Banggood]])
 +|XN297| | |Can be harvested from toy transmitters like H101, H8, …| 
 +|XN297 DIY PCB| | |[[https://oshpark.com/shared_projects/ajz5Z5tu|DIY PCB]]| 
 +|XN297| |untested|[[https://www.banggood.com/Geekcreit-XN297L-2_4G-Long-Distance-Ultra-Low-Power-RF-Module-Wireless-Transceiver-Module-p-1407282.html|Banggood]]|
  
-== Mini ==+===== Configuration =====
  
-It can be found using "nrf24l01 mini" as search term [[https://www.banggood.com/NRF24L01-Mini-SMD-2_4GHz-Wireless-Module-Power-Enhanced-Version-SMD-Receiver-Transceiver-Low-Voltage-Oltage-Regulator-Board-5V-p-1495082.html|(Banggood)]]. For adding a wire antenna, see [[https://www.rcgroups.com/forums/showpost.php?p=41923007&postcount=285|this post]].+==== Overview ====
  
-^Pin^Function+^Configuration Type^Filename
-|1|VCC (needs to be bridged with CE)+|Main|config.h
-|2|GND+|Battery|battery.c
-|3|CE (needs to be bridged with VCC)| +|Radio|radio_config.txt ([[https://github.com/markusgritsch/SilF4ware/blob/master/radio_config.txt|Github]])| 
-|4|CSN+|Dshot Driver Selection|hardware.h
-|5|SCK+|Dshot Driver Configuration|depends on driver selection: drv_dshot_bidir.c (RPM Filter), drv_dshot_dma.c (DMA), drv_dshot.c (Conventional Dshot)
-|6|MOSI+|PID|Basic PIDs are set in the main config file
-|7|MISO+|PID Advanced Configuration|pid.c
-|8|IRQ (not used)|+|PID Level Mode Configuration|angle_pid.c|
  
-== PA LNA (GT-24) ==+==== Basic Configuration ====
  
-It can be found with "GT-24" as search term [[https://www.banggood.com/GT-24-Digital-Wireless-Module-2_4G-NRF24L01-PA-LNA-Industrial-Grade-1100M-Long-Distance-With-Non-wel-p-1361350.html|(Banggood)]]. For adding an U.FL antenna, see [[https://www.rcgroups.com/forums/showpost.php?p=42688011&postcount=640|this post]].+=== Battery Cell Count ===
  
-=== XN297 ===+Default setup is configured for 4S batteries. Make sure to adjust CELL_COUNT_UNSCALED in battery.c if needed, e.g. for a 2S setup: 
 +<code>
  
-  * Can be harvested from toy transmitters like H101, H8, … +#define CELL_COUNT_UNSCALED 2 // Voltage divider, idle_offsetand PID values tuned for 4S.
-  * [[https://oshpark.com/shared_projects/ajz5Z5tu|DIY PCB]] +
-  * There is a XN297L module commercially available ([[https://www.banggood.com/Geekcreit-XN297L-2_4G-Long-Distance-Ultra-Low-Power-RF-Module-Wireless-Transceiver-Module-p-1407282.html|Banggood]])but no one has tested it yet.+
  
-==== Flight Controller ====+</code>
  
-=== Omnibus ===+=== Receiver ===
  
-It lacks BOOT buttonbut the LRD gesture can be used to switch it into DFU mode.+The default configuration is setup for NRF24 modules. If using NRF24 module with PA LNA, it is recommended to adjust TX_POWER in SilF4ware/config.h:
  
-See [[https://github.com/markusgritsch/SilF4ware/blob/master/STM32F405 Omnibus/board_pinout.jpg|SilF4ware/STM32F405 Omnibus/board_pinout.jpg]] 
- 
-^Omnibus^NRF24 Mini| 
-|3.3V|VCC (bridge with CE)| 
-|GND|GND| 
-| |CE (bridge with VCC)| 
-|SBUS_PPM|CSN| 
-|LED_STRIP|SCK| 
-|TX1|MOSI| 
-|RX1 (DSM)|MISO| 
-| |IRQ| 
- 
-=== NOX === 
- 
-See [[https://github.com/markusgritsch/SilF4ware/blob/master/STM32F411 NOXE/board_pinout.jpg|SilF4ware/STM32F411 NOXE/board_pinout.jpg]] 
- 
-^NOX^NRF24 Mini| 
-|3.3V|VCC (bridge with CE)| 
-|GND|GND| 
-| |CE (bridge with VCC)| 
-|NSS A15|CSN| 
-|CLK B03|SCK| 
-|MOSI B05|MOSI| 
-|MISO B04|MISO| 
-| |IRQ| 
- 
-=== NOX v1 === 
- 
-===== Basic Configuration ===== 
- 
-Main configuration is done in SilF4ware/config.h. 
- 
-==== Receiver ==== 
- 
-The default configuration is setup for NRF24 modules. If using a NRF24 module with PA LNA, it is recommended to adjust TX_POWER in SilF4ware/config.h: 
 <code> <code>
- 
 #define TX_POWER 1 // 0 .. 3 (use 1 when using an nRF24L01 PA LNA module) #define TX_POWER 1 // 0 .. 3 (use 1 when using an nRF24L01 PA LNA module)
  
Line 85: Line 57:
 If using a XN297 module, see [[https://github.com/markusgritsch/SilF4ware/blob/master/radio_config.txt|radio_config.txt]] file for configuration notes. If using a XN297 module, see [[https://github.com/markusgritsch/SilF4ware/blob/master/radio_config.txt|radio_config.txt]] file for configuration notes.
  
-==== Battery Cell Count ====+=== Dshot ===
  
-Default setup is configured for 4S batteriesMake sure to adjust CELL_COUNT_UNSCALED in SilF4ware/battery.c if needed. As an example, for a 2S setup:+Default setup is configured for using Dshot with RPM FilterIf using this configuration, make sure that the number of magnets on the motor bell is set correct (drv_dshot_bidir.c):
 <code> <code>
  
-#define CELL_COUNT_UNSCALED 2 // Voltage divider, idle_offset, and PID values tuned for 4S. 
- 
-</code> 
- 
-==== Dshot ==== 
- 
-Default setup is configured for using Dshot 300+RPM Filter. If using RPM Filter, the number of magnets on the motor bell needs to be configured correctly in SilF4ware/drv_dshot_bidir.c: 
- 
-<code> 
 #define MOTOR_POLE_COUNT 14 // usually on 22xx motors and above #define MOTOR_POLE_COUNT 14 // usually on 22xx motors and above
 // #define MOTOR_POLE_COUNT 12 // usually on 18xx motors and below // #define MOTOR_POLE_COUNT 12 // usually on 18xx motors and below
Line 104: Line 67:
 </code> </code>
  
-If using conventional D-Shot, adjust SilF4ware/hardware.h:+Other Dshot drivers can be selected in hardware.h:
  
 <code> <code>
Line 113: Line 76:
 </code> </code>
  
-==== 2D/3D Flying ====+=== 2D/3D Flying ===
  
 3D flying is enabled by default. If using a 2D setup, following changes are needed: 3D flying is enabled by default. If using a 2D setup, following changes are needed:
Line 126: Line 89:
 </code> </code>
  
-In the dshot configuration file (when using RPM Filter: drv_dshot_bidir.c):+In the dshot configuration file (e.g. when using RPM Filter: drv_dshot_bidir.c):
  
 <code> <code>
Line 134: Line 97:
 </code> </code>
  
-==== Misc ====+=== Misc ===
  
   * Props out configuration is enabled by default (comment INVERT_YAW_PID to disable it)   * Props out configuration is enabled by default (comment INVERT_YAW_PID to disable it)
   * Default rates are very high, adjust them if needed   * Default rates are very high, adjust them if needed
-  * PID configuration for acro mode is done in SilF4ware/pid.c and for level mode in SilF4ware/angle_pid.c+ 
 +===== Compiling & Flashing ===== 
 + 
 +It is recommended to use STM32CubeIDE for compiling SilF4ware. Keil uVision can also be used, but it produces some non-working binary when using lot's of RAM. Change FFT_SIZE in fft.h to 2048 when using Keil. 
 + 
 +Flashing can be done with betaflight-configurator. After compiling, the target files can be found in the "Release" directory. 
 + 
 +===== Using ===== 
 + 
 +==== Gestures ==== 
 + 
 +When you are used to use other silverware branches, please note that the gestures for PID tuning are swapped. 
 + 
 +|LRU|reboot flight controller| 
 +|LRD|switch to DFU mode| 
 +|LLU|switch to motors test mode| 
 +|LLD|exit motors test mode| 
 +|UUU|toggle autobind flag (remember to save with DDD)| 
 +|UDD|switch to the next PID column| 
 +|UDU|switch to the next PID row| 
 +|DDD|save configuration| 
 + 
 + 
 +==== Motors test mode ==== 
 + 
 +With default setup, when using LLU stick gesture (Left, Left, Up) SilF4ware switches into motor test mode (MOTORS_TO_THROTTLE)It can be used to verify that the configured motor order is correct, but also to check for bad/noisy props. 
 + 
 +In motor test mode, push the stick in the corresponding direction, e.g. left up will make the motor spin which is configured as front left. 
 + 
 +LLD stick gesture (Left, Left, Down) turns this mode off again. 
 + 
 +If you are used to other silverware branches, please note that with SilF4ware it is not needed to adjust the idle offset to make sure that only one motor spins. 
 + 
 +==== Devo TX ==== 
 + 
 +A Devo 7E build and model file which is able to display PID values can be found in [[https://www.rcgroups.com/forums/showpost.php?p=42032515&postcount=398|this post]]. Note that it will only display PIDs set via gestures, not when set via analog aux channels.
  
 ===== Advanced Features ===== ===== Advanced Features =====
Line 145: Line 143:
  
 The variables aux_analog[ 0 ] and aux_analog[ 1 ] hold a value between 0.0 and 2.0 which can be used in various places in the code. Per default they are used to tweak Kp and Kd respectively. This is done in SilF4ware/pid.c: The variables aux_analog[ 0 ] and aux_analog[ 1 ] hold a value between 0.0 and 2.0 which can be used in various places in the code. Per default they are used to tweak Kp and Kd respectively. This is done in SilF4ware/pid.c:
- 
 <code> <code>
 +
 #define AA_pidkp ( x <2 ? pdScaleValue * aux_analog[ 0 ] : 1.0f ) // Scale Kp and Kd only for roll and pitch. #define AA_pidkp ( x <2 ? pdScaleValue * aux_analog[ 0 ] : 1.0f ) // Scale Kp and Kd only for roll and pitch.
 #define AA_pidki 1.0f #define AA_pidki 1.0f
Line 176: Line 174:
 Blackbox logging is possible with an external logging device. See details [[https://www.rcgroups.com/forums/showthread.php?3294959-SilF4ware-an-STM32F4-port-of-SilverWare/page45#post42779217|here]] Blackbox logging is possible with an external logging device. See details [[https://www.rcgroups.com/forums/showthread.php?3294959-SilF4ware-an-STM32F4-port-of-SilverWare/page45#post42779217|here]]
  
-===== Using ===== +=====   =====
- +
-==== Gestures ==== +
- +
-  * PID Tuning: some gestures have been swapped in comparison to other silverware branches: UDD switches to the next column and UDU to the next row +
-  * LRU: reboot flight controller (nice when otherwise one would unplug and replug the battery) +
-  * LRD: switch to DFU mode (nice if the BOOT button is mechanically hard to reach after installing the FC into a quad) +
- +
-==== Motors test mode ==== +
- +
-With default setup, when using LLU stick gesture (Left, Left, Up) SilF4ware switches into motor test mode (MOTORS_TO_THROTTLE). It can be used to verify that the configured motor order is correct, but also to check for bad/noisy props. +
- +
-In motor test mode, push the stick in the corresponding direction, e.g. left up will make the motor spin which is configured as front left. +
- +
-LLD stick gesture (Left, Left, Down) turns this mode off again. +
- +
-If you are used to other silverware branches, please note that with SilF4ware it is not needed to adjust the idle offset to make sure that only one motor spins. +
- +
-==== Devo TX ==== +
- +
-A Devo 7E build and model file which is able to display PID values can be found in [[https://www.rcgroups.com/forums/showpost.php?p=42032515&postcount=398|this post]]. Note that it will only display PIDs set via gestures, not when set via analog aux channels.+
  
 ====   ==== ====   ====
silf4ware.1588095164.txt.gz · Last modified: 2020/04/28 19:32 by d7ab6ba3