STM32F0 RTC using HSE/32 as the timing source

This is only a short post really. With my watch, I’d been trying for AGES to try and get the RTC working with the external crystal. It might seem simple to some but it was certainly not simple to me and ST don’t give an example, unlike most things; in their standard peripheral downloadable pack. I […]

Monotonous Wednesdays – Creating an extremely simple waveform viewer using the STM32F0 Discovery board and ILI9163 LCD

Well! Today, I didn’t feel like doing anything particularly productive so libraries were pretty much not an option. Instead, I decided to make a really simple oscilloscope which merely displays the current sample voltage and a trace of the samples on the screen using my ILI9163 and graphics libraries. The input voltage is specified from […]

HD44780 Library update!

Since printing floating points is probably much more important than the speed of this library, I’ve included a new function that allows the printing of floating point numbers! The function explanation is really simple and here it is: int8_t PNumF(float Num, uint8_t X, uint8_t Y, uint8_t Prec)Just like with the standard PNum function, this function […]

Interfacing the HC-SR04 ultrasonic distance sensor and the STM32F0 Discovery board!

A few months back, I bought myself a cheap SR04 ultrasonic rangefinder (Datasheet: http://goo.gl/LBZeDG), as per off the magical eBay (Example – Link will expire: http://goo.gl/h9j79O). As you can imagine, these things are ridiculously cheap at a mere 99p inc. p+p. How that is even profitable, I’ll never know! They’re actually pretty nice devices and allow for […]

HD44780 Library and more!

Well in light of my recent hardware addition, I’ve decided to convert the basis of my HD44780 code into a standalone library. I’ve also added the ability to print signed integer numbers with padding with my whole code including examples compiling to < 3.5k at O0 optimization! Snazzy or what, with O3 optimization, I’ve managed […]

HD44780 LCD with PWM LED Backlight control

And voila! As I said in one of the last two posts (Initial post: https://hsel.co.uk/2014/08/14/stm32f0-discovery-board-and-the-hd44780-lcd/ and integrating a charge pump for backlight control: https://hsel.co.uk/2014/08/14/stm32f0-discovery-board-with-hd44780-and-integrated-charge-pump/), I’ve now included a generic LED backlight PWM controller using one of the standard GPIO pins. I’m using GPIOA Pin 6 to drive the LED backlight and I’ve integrated a 4bit (16 step) backlight […]

STM32F0 Mini tutorial – Using the I2C peripheral to communicate with a HMC5883L digital compass IC

Well! I’ve had a fair few requests in the past few weeks about how I got the HMC5883L digital compass IC working with my STM32F0 discovery board (as shown in a previous post: https://hsel.co.uk/2014/05/29/hmc5883l-magnetometer/). I’m really not a fan of the I2C implementation on the STM32F0 discovery board as many things don’t seem particularly apparent at […]

Servo tester part 2.

So! I decided that I wanted to properly test my servo tester (testing a tester… wuhhh?) so I bought myself some really cheap servo’s on eBay. When I say really cheap, I mean REALLY cheap! I spent a whopping £3.99 on a pair and that was with postage included (eBay Item: http://goo.gl/fACHpo as per usual, link […]