Mav to Msp STM32F042
Posted: Sun May 17, 2020 10:13 am
Hi all, i'm new to the forum was unsure if i should post here or new members section, but as its a little board that i made for an existing arduino project i thought i should post here. I make these at home with a small toaster oven, stencils etc and a cheap microscope, but they come out well.
The board is based on STM32F042G6, I wanted a cheap cpu with 32k so this is what i chose, at 4x4mm it fits perfectly. The board converts mavlink protocol to MSP, which then allows an osd to work on a set of DJI FPV goggles, I didn't write the code https://github.com/d3ngit/djihdfpv_mavlink_to_msp_V2 unfortunately for me i try but can never get my head around writing, but i'm pretty good at making boards. I love playing with hardware.
This is the board.
Its works fine no issues, because of the STM32duino project it has allowed me to use STM processors, so huge thank you for that.
So now i have a couple of technical software questions. I followed the wiki and was able to add the new variant with ease (version 1.8.0) but i couldn't get the serial 2 working when i add these lines to the variant.h file
But if i add the following line to the arduino sketch then all works as it should, no problem as there is a workaround but thought i would ask if i had done something wrong.
Also with 1.9.0 there is an error with wkup 2 & 7 in PinNamesVar.h, i have looked up the data sheet and everything is correct. If i add pins from a larger CPU then all builds as expected, i didn't have this issue with 1.8.0.
Anyway, my name is Malcolm, and once again, thanks for a great project.
The board is based on STM32F042G6, I wanted a cheap cpu with 32k so this is what i chose, at 4x4mm it fits perfectly. The board converts mavlink protocol to MSP, which then allows an osd to work on a set of DJI FPV goggles, I didn't write the code https://github.com/d3ngit/djihdfpv_mavlink_to_msp_V2 unfortunately for me i try but can never get my head around writing, but i'm pretty good at making boards. I love playing with hardware.
This is the board.
Its works fine no issues, because of the STM32duino project it has allowed me to use STM processors, so huge thank you for that.
So now i have a couple of technical software questions. I followed the wiki and was able to add the new variant with ease (version 1.8.0) but i couldn't get the serial 2 working when i add these lines to the variant.h file
Code: Select all
// Default pin used for 'Serial2' instance
#define SERIAL_UART_INSTANCE 2
#define PIN_SERIAL2_RX PA3 //RX2
#define PIN_SERIAL2_TX PA2 //TX2
Code: Select all
HardwareSerial Serial2(PA_3, PA_2);
Anyway, my name is Malcolm, and once again, thanks for a great project.