STM32F0 Port

More
05 Feb 2018 08:29 - 05 Feb 2018 08:41 #67395 by qba667
STM32F0 Port was created by qba667
Recently I have undertook some steps to port DeviaitonTX to STM32F0 platform - so it can be used on FlySky I6X (possibly on I6s).
As base I have taken target devo7e - because of similar flash size - should I try with some other target?

FlySky devices have no flash memory so filesytem idea can not be applied. Using I2C EEPROM for storing settings - seems to be just fine.
Removing ini handling will give us some additional space

By removing USB support and file system It seems to be just fine to store fonts and images in MCU flash.
In I6X there is additional bootloader taking 16kB of the flash - after dumping this space can be used for data/code as well.

However I see few issues:
-used libopencm3 is not up to date - tuts GPIO/RCC handling requires lot of processor definitions.
-AFHDS2 protocol is incomplete - I was working on disassembly
-I6s has no EEPROM so MCU flash must be used for emulation.

Is there anything more that I should consider?
Last edit: 05 Feb 2018 08:41 by qba667.

Please Log in or Create an account to join the conversation.

More
05 Feb 2018 08:51 #67397 by FDR
Replied by FDR on topic STM32F0 Port
The 7E stores the protocol modules on the external flash too, and load them dynamically.
So without the external storage you might not have enough space...

Please Log in or Create an account to join the conversation.

More
05 Feb 2018 09:31 - 05 Feb 2018 09:33 #67398 by qba667
Replied by qba667 on topic STM32F0 Port
I have noticed this clever loading of protocol module but I have not look closer at others protocol modules than AFHDS2a. But size reserved for module is only 4kB
ram (rwx) : ORIGIN = 0x20004000, LENGTH = 4K
Few of them will fit for sure, if someone needs more some exchange mode must be applied.
I believe AFHDS 2A code can grow a little - and it should be part of firmware itself. Maybe 2 modules can be stored in EEPROM.
I need to check what is size of data like fonts and images to get better size estimation.
Last edit: 05 Feb 2018 09:33 by qba667.

Please Log in or Create an account to join the conversation.

More
05 Feb 2018 10:34 #67399 by Fernandez
Replied by Fernandez on topic STM32F0 Port
I would love to flash my Turnigy Evolution to deviation!
Even if some soldering is needed, adding a flash memory chip or replacing the CPU, I am in for it !

I think "fishpepper" also have some good info on the pinmappings on the Flysky, who added a cc2500, to make it Frsky.

Please Log in or Create an account to join the conversation.

More
05 Feb 2018 11:30 - 12 Feb 2018 14:43 #67400 by qba667
Replied by qba667 on topic STM32F0 Port
Yes fishpepper did own firmware for I6s and Evolution. I was inspired by his work when I was working on I6 firmware.
I will try to remove other file system dependencies and I will let you know what is the size of resulting binary.
DeviaitonTX compiled for STM32F0 based on Devo7e without protocol code, fonts, images and configuration management (saving, loading, templates) needs:
ROM: 0x08003000 - 0x0801969c = 89.65kB
RAM: 0x20000000 - 0x20001e38 = 7.55kB
What do you think will it fit?
I have worked on pin-out recently - it looks that radio has second SPI nicely exposed.

Next finding MCU can be updated to F103VET but additional wiring is necessary - pads for additional SPI must be wired to current module - and pin used for bind button (guess) is not connected in F1.
Another usage of exposed SPI port can be adding SPI flash or sd card.
Attachments:
Last edit: 12 Feb 2018 14:43 by qba667.

Please Log in or Create an account to join the conversation.

More
23 Aug 2018 12:52 - 23 Aug 2018 12:53 #70405 by kaligola
Replied by kaligola on topic STM32F0 Port
if you do this evolution will be quite nice radio with expo and rates.

wow
Last edit: 23 Aug 2018 12:53 by kaligola.

Please Log in or Create an account to join the conversation.

More
10 Jun 2020 18:53 #76447 by marianomd
Replied by marianomd on topic STM32F0 Port
This is so nice and inspiring. @qba667 could you do any progress on this?

Please Log in or Create an account to join the conversation.

Time to create page: 0.048 seconds
Powered by Kunena Forum