First pass at a BluePill Variant

The official STMicroelectronics Arduino core
evge.05
Posts: 11
Joined: Sat Aug 20, 2016 1:46 pm
Location: Russia

Re: First pass at a BluePill Variant

Post by evge.05 » Mon Sep 19, 2016 12:26 pm

i've just reinstall arduino IDE and copied core again. But arduino IDE doesn't see new core whith nucleo boards. Rogers core works fine. Very strange things.
sorry. Maybe I've made somethings wrong, but this core works only if it copy to folder whith Rogers core https://github.com/rogerclarkmelbourne/Arduino_STM32 In other case arduino IDE doesn't see Rick core.

User avatar
Rick Kimball
Posts: 951
Joined: Tue Apr 28, 2015 1:26 am
Location: Eastern NC, US
Contact:

Re: First pass at a BluePill Variant

Post by Rick Kimball » Mon Sep 19, 2016 1:09 pm

I have mine extracted to :
Arduino/hardware/st/stm32f1

following the vendor/architecture model from

https://github.com/arduino/Arduino/wiki ... 1.0-to-1.6
-rick

evge.05
Posts: 11
Joined: Sat Aug 20, 2016 1:46 pm
Location: Russia

Re: First pass at a BluePill Variant

Post by evge.05 » Mon Sep 19, 2016 1:19 pm

well, i've extracted to /documents/Arduino/Hardware/stm32f1-master - doesn't work. Than i've extracted Rogers core to /documents/Arduino/Hardware/stm32f1 - everything is work. Than i've copied Rick core to /documents/Arduino/hardware/stm32f1/ and it appears in arduino ide.

User avatar
Rick Kimball
Posts: 951
Joined: Tue Apr 28, 2015 1:26 am
Location: Eastern NC, US
Contact:

Re: First pass at a BluePill Variant

Post by Rick Kimball » Mon Sep 19, 2016 1:29 pm

Probably the right place would be:

$ pwd
/home/kimballr/Arduino/hardware/stm32duino/stm32f1
$ ls
boards.txt cores libraries platform.txt programmers.txt README.md system variants

where stm32duino is the vendor
and stm32f1 is the architecture

For linux it looks like this:

Code: Select all

$ mkdir -p $HOME/Arduino/hardware/stm32duino
$ cd $HOME/Arduino/hardware/stm32duino
$ git clone https://github.com/RickKimball/Arduino_Core_STM32F1.git stm32f1
$ ls stm32f1
boards.txt  cores  libraries  platform.txt  programmers.txt  README.md  system  variants
Go back and read https://github.com/arduino/Arduino/wiki ... 1.0-to-1.6

Step 1: Move core files into a vendor/architecture folder structure.

The new Arduino IDE introduced support for boards that use CPU architectures different from AVR. Cores for each architecture now reside in their own folder. Therefore we must move the core files inside a folder structure where the first folder is the name of the vendor and the second folder is the name of the architecture, that is: move everything into sparkfun/avr/
...


-rick
-rick

evge.05
Posts: 11
Joined: Sat Aug 20, 2016 1:46 pm
Location: Russia

Re: First pass at a BluePill Variant

Post by evge.05 » Mon Sep 19, 2016 1:35 pm

i'm win10 user.

User avatar
Rick Kimball
Posts: 951
Joined: Tue Apr 28, 2015 1:26 am
Location: Eastern NC, US
Contact:

Re: First pass at a BluePill Variant

Post by Rick Kimball » Mon Sep 19, 2016 1:40 pm

So I guess it needs to end up in:

C:\someuserdir\Documents\Arduino\hardware\stm32duino\stm32f1\boards.txt ?
Last edited by Rick Kimball on Mon Sep 19, 2016 2:40 pm, edited 2 times in total.
-rick

evge.05
Posts: 11
Joined: Sat Aug 20, 2016 1:46 pm
Location: Russia

Re: First pass at a BluePill Variant

Post by evge.05 » Mon Sep 19, 2016 1:57 pm

C:\Users\evgen\Documents\Arduino\hardware\Arduino_STM32-master\ArduinoSTM32F1\boards.txt - this variant is work.
C:\Users\evgen\Documents\Arduino\hardware\ArduinoSTM32F1\boards.txt - this variant doesn't work.

User avatar
Rick Kimball
Posts: 951
Joined: Tue Apr 28, 2015 1:26 am
Location: Eastern NC, US
Contact:

Re: First pass at a BluePill Variant

Post by Rick Kimball » Mon Sep 19, 2016 7:31 pm

RogerClark wrote: ...
I wonder why they had the "Arduino_id" in the pin map
I assume they are trying to use the same pin numbers as a classic arduino board.
RogerClark wrote: I didnt think the Anlogue pins would be different.
That table contains all the pins. However there are 3 other PinMap (digital, analog and interrupt ) that are populated using the table you mentioned.

Their whole scheme seems to be more complicated and not really geared for multiple variants. Looking at the file stm32f1/system/libstm32f1/source/analog.c it is really using the variant.cpp pinmap to decide how the pins are configured for Timers to support PWM. The same can be said about the uart.c file which makes pin assumptions about the uarts. Both of these files shouldn't be in the libstm32f1 directory as they are really associated with a specific board. Or if they are in the lib, they shouldn't be making decisions based on board specific pins.

-rick
Last edited by Rick Kimball on Mon Sep 19, 2016 7:39 pm, edited 1 time in total.
-rick

User avatar
Rick Kimball
Posts: 951
Joined: Tue Apr 28, 2015 1:26 am
Location: Eastern NC, US
Contact:

Re: First pass at a BluePill Variant

Post by Rick Kimball » Mon Sep 19, 2016 7:36 pm

Before I spend too much time on this, I'll wait for the ST team to declare victory and indicate they are done. Do you plan on doing anything more with the STM32F1 code @fpiSTM ?

-rick
-rick

User avatar
RogerClark
Posts: 6405
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: First pass at a BluePill Variant

Post by RogerClark » Mon Sep 19, 2016 8:28 pm

Rick did you see the post from Wi6labs?

I moved it to this section.

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests