Added target FLYWOOF405NANO
Hi team, in collaboration with Flywoo dev team I've created the GOKU GN405 target.
Target name FLYWOOF405NANO
This is the board: https://flywoo.net/collections/explorer-lr-4-part/products/c702-goku-gn405-nano-13a-stack-w-4pcs-ws2812-led-16-16
The code has already been tested on a board.
Hi,
Please take a look at https://github.com/iNavFlight/inav/blob/master/docs/policies/NEW_HARDWARE_POLICY.md And if possible, pass the info to the flywoo dev team too
Thanks for your replya and drive me to the Policy.
I guess the point 3 of the "New target addition" chapter is suttisfied (the chapter state that one only is required):
- On-board sensors include at least the IMU (gyroscope + accelerometer): yes, ICM42688 \ MPU6000
- At least 2 hardware serial ports are available with both TX and RX pins: 5 UART are available
- At least 512K of firmware flash memory and at least of 64K of RAM available: yes
- At least one I2C bus broken out (SCL and SDA pins) and not shared with other functions: yes
This device is a variation of many others STM32 F405 already supported, so I guess it will not require additional effort to the dev team, but it will grant additional adoption. Flywoo is growing and makeing innovative drones, like the last Explorer LR4 with DJI O3 that is based on this FC. Having an official INAV release for this drone it will be good point.
Flashed and it works correctly. One difference vs stock one needs to set ibat scale to 170.
Tnaks for your contribution.
I've an other issue I'm not able to solve: the same target for BF own the Serial 2. I've added
#define USE_UART2 #define UART2_TX_PIN PD5 #define UART2_RX_PIN PD6
D5 and D5 are the same Pin used in the BF configuration, but when compiling i get this error:
/src/src/main/drivers/io_def_generated.h:576:25: error: 'defio_error_PD6_is_not_supported_on_TARGET' undeclared here (not in a function) 576 | # define DEFIO_TAG__PD6 defio_error_PD6_is_not_supported_on_TARGET | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /src/src/main/drivers/io_def_generated.h:576:25: note: in definition of macro 'DEFIO_TAG__PD6' 576 | # define DEFIO_TAG__PD6 defio_error_PD6_is_not_supported_on_TARGET | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /src/src/main/common/utils.h:30:21: note: in expansion of macro 'CONCAT_HELPER' 30 | #define CONCAT(x,y) CONCAT_HELPER(x, y) | ^~~~~~~~~~~~~ /src/src/main/drivers/io_def.h:7:26: note: in expansion of macro 'CONCAT' 7 | #define DEFIO_TAG(pinid) CONCAT(DEFIO_TAG__, pinid) | ^~~~~~ /src/src/main/drivers/io.h:34:23: note: in expansion of macro 'DEFIO_TAG' 34 | #define IO_TAG(pinid) DEFIO_TAG(pinid) | ^~~~~~~~~ /src/src/main/drivers/serial_uart_stm32f4xx.c:71:11: note: in expansion of macro 'IO_TAG' 71 | .rx = IO_TAG(UART2_RX_PIN), | ^~~~~~ /src/src/main/drivers/io_def_generated.h:567:25: error: 'defio_error_PD5_is_not_supported_on_TARGET' undeclared here (not in a function) 567 | # define DEFIO_TAG__PD5 defio_error_PD5_is_not_supported_on_TARGET | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /src/src/main/drivers/io_def_generated.h:567:25: note: in definition of macro 'DEFIO_TAG__PD5' 567 | # define DEFIO_TAG__PD5 defio_error_PD5_is_not_supported_on_TARGET | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /src/src/main/common/utils.h:30:21: note: in expansion of macro 'CONCAT_HELPER' 30 | #define CONCAT(x,y) CONCAT_HELPER(x, y) | ^~~~~~~~~~~~~ /src/src/main/drivers/io_def.h:7:26: note: in expansion of macro 'CONCAT' 7 | #define DEFIO_TAG(pinid) CONCAT(DEFIO_TAG__, pinid) | ^~~~~~ /src/src/main/drivers/io.h:34:23: note: in expansion of macro 'DEFIO_TAG' 34 | #define IO_TAG(pinid) DEFIO_TAG(pinid) | ^~~~~~~~~ /src/src/main/drivers/serial_uart_stm32f4xx.c:72:11: note: in expansion of macro 'IO_TAG' 72 | .tx = IO_TAG(UART2_TX_PIN), | ^~~~~~ make[3]: *** [src/main/target/FLYWOOF405NANO/CMakeFiles/FLYWOOF405NANO.elf.dir/build.make:180: src/main/target/FLYWOOF405NANO/CMakeFiles/FLYWOOF405NANO.elf.dir/__/__/drivers/serial_uart_stm32f4xx.c.obj] Error 1 make[2]: *** [CMakeFiles/Makefile2:20325: src/main/target/FLYWOOF405NANO/CMakeFiles/FLYWOOF405NANO.elf.dir/all] Error 2 make[1]: *** [CMakeFiles/Makefile2:20386: src/main/target/FLYWOOF405NANO/CMakeFiles/FLYWOOF405NANO.dir/rule] Error 2 make: *** [Makefile:6826: FLYWOOF405NANO] Error 2
Any clue?
I've updated the Target.h as suggested but now I've an issue with the configurator: all sensor icons are off
Sensors pages shows that everythings works fine and there are no others changes. Any clue?
System Uptime: 1139 seconds Current Time: 2022-12-29T12:28:24.528+01:00 Voltage: 0.62V (1S battery - NOT PRESENT) CPU Clock=168MHz, GYRO=MPU6000, ACC=MPU6000, BARO=BMP280, MAG=HMC5883 STM32 system clocks: SYSCLK = 168 MHz HCLK = 168 MHz PCLK1 = 42 MHz PCLK2 = 84 MHz Sensor status: GYRO=OK, ACC=OK, MAG=OK, BARO=OK, RANGEFINDER=NONE, OPFLOW=NONE, GPS=OK Stack size: 6144, Stack address: 0x10010000, Heap available: 1728 I2C Errors: 0, config size: 8938, max available config: 131072 ADC channel usage: BATTERY : configured = ADC 1, used = ADC 1 RSSI : configured = ADC 3, used = none CURRENT : configured = ADC 2, used = ADC 2 AIRSPEED : configured = none, used = none System load: 10, cycle time: 507, PID rate: 1972, RX rate: 9, System rate: 9 Arming disabled flags: NAV RX CLI DSHOTBEEPER VTX: not detected

I've updated the Target.h as suggested but now I've an issue with the configurator: all sensor icons are off
You need the latest configurator from the master, the released one is not compatible with inav 6x
huuu .. ok, tnx
huuu .. ok, tnx
Will this work release with the Flywoo GOKU GN405S 20A AIO and 40A AIO targets? If not could you pursue this? Thank you.
Unfortunatelly I havn't those board to test the related release, so I can't confirm.
@sdellava Please tell me about what is the status of development now. I pulled and checked the master branch of iNavFlight/inav and could not find FLAYWOOF405NANO in the make targets. Thanks.
The new Taget will be merged in the next official release.
@sdellava
Thank you! How can I try your changes prior to the merge? Would it be OK if I pull your fork?
Yes it works, but you need to compile it and of course it will miss all other PR that in the mean time has been submitted.
@sdellava Thank you for your kind explanation. I have checked your commit in sdellava/inav. I will use it.
Buongiorno Stefano, I bought the Goku Versatile F405 Pro Mini Stack convinced that the FLYWOOF405NANO driver worked correctly, as indicated by Flywoo, unfortunately it didn't. My questions to them remained unanswered, but luckily I found this thread and decided to write the driver for this stack thanks to your work. This morning I tested the driver and it seems to work correctly, so I think the target for this fc will have to be FLYWOOF405PRO
This is the board: https://flywoo.net/products/goku-versatile-f405-pro-mini-stack-f405-fc-40a-esc-8bit-2-6s-20-x20
@nisaji thanks for your feedback. I've tested my fork on this board with https://flywoo.net/products/c702-goku-gn405-nano-13a-stack-16-16 and I've got no issues. So maybe the target is good for both the FC versions
why is this target not merged in the 6.0 release :( I was looking forward to this for a long time :(
I was waiting for this board to be included with the 6.0 release. What happened? I have a ZOHD Drift waiting for it
I compiled this target myself with 6.0: inav_6.0.0_FLYWOOF405NANO.hex
I compiled this target myself with 6.0: inav_6.0.0_FLYWOOF405NANO.hex
Thank you @StormYudi I install the firmware but there are no sensors information, only baromether. I see on this thread that I have to use the "master" configurator but I can´t find it to just install or run it on windows without compiling. Maybe I´m wrong or missing something? @sdellava any idea if this firmware is going to be relesed with a new iNav 6 configurator? By the way thanks for building it!
This target seems to not include support for the ICM42688 gyro, the target config only includes MPU6000 and BMI270 support from what I can tell.
I validated the following added config to work with the ICM gyro:
#define USE_IMU_ICM42605
#define IMU_ICM42605_ALIGN CW90_DEG
#define ICM42605_CS_PIN PB12
#define ICM42605_SPI_BUS BUS_SPI1
Note: apparently, UART2 was listed in the target before, but this config does not have it. Is there some reason for it being removed?
@Molecuman unfortunatelly I can't do nothing. I'm not part of Flywoo organization. I've just recevied from the the information to build the correct target, compiled and tested the image.
This target seems to not include support for the ICM42688 gyro, the target config only includes MPU6000 and BMI270 support from what I can tell.
I validated the following added config to work with the ICM gyro:
#define USE_IMU_ICM42605 #define IMU_ICM42605_ALIGN CW90_DEG #define ICM42605_CS_PIN PB12 #define ICM42605_SPI_BUS BUS_SPI1Note: apparently, UART2 was listed in the target before, but this config does not have it. Is there some reason for it being removed?
Thanks for your contribution. I've got the config file from Flywoo and the UART2 wasn't there. I've tried to add it but I got error in compiling, so I've removed from the final config.
Unfortunatelly I don't know how to solve the compiler errors when UART2 is configured.
Hi did you base your target off this? (scroll down) https://flywoo.tawk.help/article/firmware-inav
is this newer than/ is your version? found it on a reddit thread: https://www.reddit.com/r/fpv/comments/vn1tkv/flywoo_explorer_4_running_inav/
This target seems to not include support for the ICM42688 gyro, the target config only includes MPU6000 and BMI270 support from what I can tell. I validated the following added config to work with the ICM gyro:
#define USE_IMU_ICM42605 #define IMU_ICM42605_ALIGN CW90_DEG #define ICM42605_CS_PIN PB12 #define ICM42605_SPI_BUS BUS_SPI1Note: apparently, UART2 was listed in the target before, but this config does not have it. Is there some reason for it being removed?
Thanks for your contribution. I've got the config file from Flywoo and the UART2 wasn't there. I've tried to add it but I got error in compiling, so I've removed from the final config.
Unfortunatelly I don't know how to solve the compiler errors when UART2 is configured.
Thank you for this tidbit on using the ICM42605 setting for the ICM-42688-P gyro! It helped me get my Flywoo Explorer LR V2.2 working with INAV 6.1.0.
I'd like to help resolve the UART2 issue. The STM32F405OE datasheet says PD5 and PD6 are both available on the WLCSP90 package used on this FC on pins C6 and B5, respectively. Can you please identify or share the config file from Flywoo so I can see what might be missing?
Will this work release with the Flywoo GOKU GN405S 20A AIO and 40A AIO targets? If not could you pursue this? Thank you.
I flashed a Flywoo Cinerace20 DJI O3 which has the GOKU GN405S 20A AIO. I built a copy of the FLYWOOF405PRO target #9115 (which appears to be the FLYWOOF405NANO target #8606 with ICM42605 added). I confirmed ICM42605 working on two different Flywoo F405 FC's that both have the ICM-42688-P gyro.
BF target name for the GOKU GN405S 20A AIO is FLYWOOF405S_AOI. This is the board: https://flywoo.net/products/goku-gn-405s-20a-aio-bmi270-25-5-x-25-5
Other changes noted:
- Motor mappings are different. This can be reassigned in INAV Configurator.
- Gyro orientation is CW270 instead of CW180_DEG_FLIP.
#define IMU_ICM42605_ALIGN CW270_DEG
Should/can a new INAV target be created for FLYWOOF405S_AOI?
Tnaks for your contribution.
I've an other issue I'm not able to solve: the same target for BF own the Serial 2. I've added
#define USE_UART2 #define UART2_TX_PIN PD5 #define UART2_RX_PIN PD6
D5 and D5 are the same Pin used in the BF configuration, but when compiling i get this error:
`/src/src/main/drivers/io_def_generated.h:576:25: error: (TRIMMED)
Any clue?
I found what causes the compiler error:
#define TARGET_IO_PORTD (BIT(2))
should be changed to:
#define TARGET_IO_PORTD 0xffff
I see the former in many other targets, so it must have been a carryover from other FC's that have much fewer UARTs/pins.
As for why UART2 is missing... Flywoo probably saw INAV Configurator only showed 6 ports in the Ports tab, but they needed UART6 for GPS. Their easy fix must have been to omit/delete unused UART2. A better solution is to change:
#define SERIAL_PORT_COUNT 6
to
#define SERIAL_PORT_COUNT 7
I will update my pull request with these additional changes.
Hello All, I have this Flight Controller and I would like to Flash it with iNav, and the problem is that it is not yet included in the release of iNav 6.1, could somebody compile this target to .hex file? I would highly appreciate it, I am not new to Programming but the problem is that I am new with Git and Github so I am having a hard time to compile the target.
Hello All, I have this Flight Controller and I would like to Flash it with iNav, and the problem is that it is not yet included in the release of iNav 6.1, could somebody compile this target to .hex file? I would highly appreciate it, I am not new to Programming but the problem is that I am new with Git and Github so I am having a hard time to compile the target.
https://github.com/sdellava/inav-6.0-FLYWOOF405NANO-
https://github.com/sdellava/inav-6.0-FLYWOOF405NANO-
Did you build this hex file with the gyro change described above by @PhilippMolitor? I added this change to PR #9252.