Spark Logic

HALMX :: MXBluePillF103C8 Roadmap

Vassilis Mon Apr 18, 2016 6:46 am

On March 2016 I started working on Sheepdoll’s (Julie S. Porter) great work on HALMX core files. I focused on STM32F103C8 MCU because it’s widely used by STM32Duino members. I think it is very hard for members to watch the whole forum posts and see what feature is added to the HALMX core.
I saw that Sheepdoll has a generic HALMX roadmap but the changes I have done so far are tested only MXBluePillF103C8 variant. Not to the entire HALMX variants. For that reason, I created this post that informs the members with the changes are made by me or any other member, to the MXBluePillF103C8 variant.

Things that work:

[14 May 2016]
* USBSerial. Added support to USB Virtual COM port.
* Bootloader. The Maple DFU firmware upload method is used to upload the compiled sketches to HALMX.

[09 May 2016]
* Added the interrupt based Serial transmission function on Serial1, 2 and 3 ports.

[19 April 2016]
* wiring_analog.c Support to AnalogRead() and AnalogWrite() functions

[14 April 2016]
* SPI library
* wiring.h The delayMicroseconds() was re-written for STM32. The previous assembly code wasn’t work correct to the tests I had made.
* wiring_digital.c The LOW and HIGH were placed in reverse on digitalRead(…). Fixed!

[09 April 2016]
* Hardware Serial ports. Serial 1, Serial 2 and Serial 3 work in Interrupt mode.

Things to do:
* Wiring library. Support to I2C interface
* SPI library in DMA and Interrupt mode.

Replies

zmemw16 Thu Jun 09, 2016 11:07 pm

apols, some devices use an odd format – 9 i thought data bits and usart was a way of interfacing to them.

off to google on the topic
stm32 usart spi 9 data bits

RogerClark Sun Jun 19, 2016 11:15 pm

Just a note for future reference

The core for the Arduino STAR OTTO seems to have I2C (Wire) code built into the core (not as a library), which uses the HAL

I suspect that this is going to be the quickest way to add Wire to the HAL MX core.

Vassilis Mon Jun 20, 2016 11:13 am

Thanks!

Vassilis Mon Jun 20, 2016 7:43 pm

Today, I slightly modified the Arduino STAR OTTO’s Wire core library to meet the F1 series needs. At the moment, the wire example sketch is compiled without error. Tomorrow I will test the core library on a real I2C slave component.
There are some definition names in the STM32F469xx.h library that are used with different names in the F1 libraries such as HAL_I2C1 (F469) instead of I2C1 (F103) .

RogerClark Mon Jun 20, 2016 9:37 pm

Hi Vassilis

I hope the Wire library has not interfered with the studies for your exams.

I was going to look at the Wire library at the weekend, but I do not have much spare time at the moment.

Vassilis Tue Jun 21, 2016 12:38 pm

@Roger
Don’t worry. I need a break from studying.

I sent you with a PR with the Wire (I2C) core library. The core library has been tested only on DS1307 device by using the RTCx library. The RTCx library can be downloaded from the “Library manager” on Arduino IDE (Sketch -> Include library -> Manage libraries).

-= The wire library has not been tested 100%. I sent the Pull Request only for testing purpose. =-

RogerClark Tue Jun 21, 2016 10:39 pm

Vassilis

No Worries….

I will accept the pull request and test on a BMP085 barometer module.

PS. I got an email from Francesco at Arduino.cc, and he has nearly finished the SDIO function.

So perhaps we can add this as a library.

Hopefully, he will email me when it is pushed to github.

ekawahyu Wed Jul 27, 2016 4:41 pm

I am trying to use the SPI interface and would like to know if somehow this will be integrated in the core in the future or will it remain as library forever? What is the reason to keep it as a library?

Vassilis Wed Jul 27, 2016 5:32 pm

ekawahyu wrote:I am trying to use the SPI interface and would like to know if somehow this will be integrated in the core in the future or will it remain as library forever? What is the reason to keep it as a library?

ekawahyu Wed Jul 27, 2016 7:24 pm

Ok, so the I2C is also provided as a library? So everything additional will be provided as libraries, except UART, PWM, and ADC, is that correct?

We could actually provide the #ifdef in the core to remove the SPI by declaring a macro such as USE_SPI1, USE_SPI2, etc.

Slammer Wed Jul 27, 2016 8:33 pm

We have to stay as close as we can to arduino official api for uno/due/zero, for compatibility reasons. In official API, SPI/I2C are loaded as external libraries.

Sign in to reply