Comments (3)
Hello @Kedrel,
Thank you for the report.
The Timeout used in I2C_WaitOnFlagUntilTimeout
for the 2 functions HAL_I2C_Master_Receive & HAL_I2C_Mem_Read is sufficient to check if the peripheral still busy.
Otherwise, can you share more details about your scenario or project?
With regards.
from stm32g0xx_hal_driver.
Hello @KRASTM,
The system i'm working on currently uses a tick of 10 ms to run the whole process. The aim is never to have a task that exceends 10ms so we can handle the "real-time" properly.
When i call "HAL_I2C_Mem_Read" using a Timeout parameter at 2 ms, inside of it we have the call of "I2C_WaitOnFlagUntilTimeout" which uses a parameter of I2C_TIMEOUT_BUSY, which is 25ms.
So if an I2C peripheral can't respond, instead of loosing 2ms of wait time like the setting i chose, i'll loose 25ms.
I can't afford to loose 25ms like that (as i have multiple I2C sensors), so i'll change the I2C_TIMEOUT_BUSY value to something acceptable for my application.
With regards.
from stm32g0xx_hal_driver.
Hello @Kedrel,
In this particular case, it is possible to modify the value of I2C_TIMEOUT_BUSY
to suit your application.
Please allow me to close this issue. Thank you for your comprehension.
With regards.
from stm32g0xx_hal_driver.
Related Issues (6)
- Issue if tick rollover occurs while waiting for flash (from the forum) HOT 2
- USB OUT stall's on high bus load HOT 5
- Data filters in LL_ADC_REG_ReadConversionDataX prevent left alignment from working HOT 5
- HAL_SPI_TransmitReceive_IT crashes when TX buffer is not 16 bit aligned HOT 3
- HAL I2C produces unwanted NACKs in slave mode HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from stm32g0xx_hal_driver.