Search found 28 matches

by Michail
Fri Jan 23, 2015 7:39 am
Forum: STM32 Support
Topic: Strange impact of CH_DBG options
Replies: 13
Views: 12182

Re: Strange impact of CH_DBG options

Am I correct in that it won't work for sensors on say PA2, PB2, PB3, because those share the same EXT interrupt line?
Yes, you are right.
Is the EXT module initialized when a conversion starts? (i.e. I could have sensors on those pins, but just the conversions can't be active at the same time) or ...
by Michail
Wed Jan 21, 2015 8:01 pm
Forum: STM32 Support
Topic: Strange impact of CH_DBG options
Replies: 13
Views: 12182

Re: Strange impact of CH_DBG options

I've updated DHT driver.
- now it supports DHT11, DHT22 or both simultaneously (should be defined in .h file). Not tested on DHT22 but should work;
- supports CRC checking;
- supports as many sensors as you want, on any pin simultaneously;
- supports any free timer (not fully tested but works ...
by Michail
Mon Jan 12, 2015 11:06 am
Forum: STM32 Support
Topic: Strange impact of CH_DBG options
Replies: 13
Views: 12182

Re: Strange impact of CH_DBG options

Michail, would be nice to expand this driver to work for DHT22 too. Your DHT11 has "binary RH data" followed by a byte "decimal RH data". You ignore the decimal one if I read the code correctly. My DHT22 has just a 16-bit field that indicates the RH in tenths of a percent. Similarly, the ...
by Michail
Mon Jan 12, 2015 5:18 am
Forum: STM32 Support
Topic: Strange impact of CH_DBG options
Replies: 13
Views: 12182

Re: Strange impact of CH_DBG options

Of course. It's not fully ready, normally works only with 1 sensor on 1 pin, but it works for me on STM32F0x...

Usage is:


DHTD1.ext_pin = DHT11_PIN;
DHTD1.ext_port = GPIOA;
DHTD1.ext_drv = &EXTD1;
DHTD1.ext_mode = EXT_CH_MODE_BOTH_EDGES | EXT_CH_MODE_AUTOSTART | EXT_MODE ...
by Michail
Mon Dec 22, 2014 12:10 pm
Forum: Development and Feedback
Topic: The RTC driver topic
Replies: 228
Views: 142864

Re: The RTC driver topic

Yes, now everything works fine!

Thank you!
by Michail
Sun Dec 21, 2014 5:06 pm
Forum: Development and Feedback
Topic: The RTC driver topic
Replies: 228
Views: 142864

Re: The RTC driver topic

Hello Barthess, hi Giovanni!

Think I've stumbled upon a bug in the RTC driver in current trunk on STM32F100C8.

In halInit() function hal_lld_init() calls before rtcInit().
hal_lld_init() calls hal_lld_backup_domain_init(), it calls rtc_lld_set_prescaler(), it calls rtc_acquire_access() and at last ...
by Michail
Wed Dec 10, 2014 12:47 pm
Forum: STM32 Support
Topic: Strange impact of CH_DBG options
Replies: 13
Views: 12182

Re: Strange impact of CH_DBG options

Hurrah, at last I won it!

Problem was in:
chSysLockFromISR();
chVTSetI(&sensor->timer, MS2ST(5), dht11_timer_handler, sensor);
extChannelEnableI(sensor->ext_drv, sensor->ext_pin);
chSysUnlockFromISR();
palSetPad(sensor->ext_port, sensor->ext_pin);
palSetPadMode(sensor->ext_port, sensor->ext ...
by Michail
Tue Dec 09, 2014 6:11 pm
Forum: STM32 Support
Topic: Strange impact of CH_DBG options
Replies: 13
Views: 12182

Re: Strange impact of CH_DBG options

Giovanni wrote:Do you have all debug options enabled?


Only shown above. In fact, all that I was changing - CH_DEBUG

Thanks for confirming my hypothesis, tomorrow I'll try to set NanoSleeps in code :)
by Michail
Tue Dec 09, 2014 12:33 pm
Forum: STM32 Support
Topic: Strange impact of CH_DBG options
Replies: 13
Views: 12182

Strange impact of CH_DBG options

Hello!

All about Chibios 3.0 from trunk, and STM32F031F4.

I'm using this driver for hymidity sensor DHT11 (founded somewhere on the internet and some modified):
#include "ch.h"
#include "hal.h"
#include "ext.h"
#include "chconf.h"
#include "core.h"

#if DHT11_PRESENT

#include ...
by Michail
Mon Sep 01, 2014 1:21 pm
Forum: Development and Feedback
Topic: [DONE] Broken RTC on ChibiOS 3
Replies: 13
Views: 10905

Re: [DONE] Broken RTC on ChibiOS 3

Got it, thank you. Now everything compiles fine!