Thanks a great Deal for this video. It helped me alot after several manhours of failed debugging. Turns out for the Nucleo F410RB, STM32CubeMX initializes the wrong pins (PB6 and 7) instead of PB8/9 as i discovered by help of your video.
Hi..I want to communicate between two stm32 of different cores via I2C, lets say between F0 and F7.F0 would be slave and F7 master.The idea is when user button on F7 board is pressed ,the control will shift to F0..but i don't know how to give a slave address to my F0 and which registers to use for address..So how can i do that and how to make sure that address is not already in use.
I did this for the STM32F446RE board, the LED2 didn't turn on, the address is the same so its a bit weird, I think maybe my board is defective. any suggestions?
The HAL documentation says that you need to shift the device address by 1 to the left before calling the interface. Is there a reason you've not done that? Also wouldn't the device address be 0xD1 when you are reading from it since the RW bit is now 1.
HPB1980 Hi, The reason datasheet suggests shift to the left by 1 is because HAL library includes Rd/Wr bit with the address. In my case, I included that directly; Address with the Rd/Wr bit is 0xD0 = 1101 0000 Without Rd/Wr bit is 01101000 = 0x68 Hope this helps
If anyone else is stuck on the 1101000 to D0 conversion like I was (or I'm just stupid hehe). 1101 Binary is "D" in hex and 0000 is "0" in hex. Gotta split it into pairs of 4 :o
Hi, i using 2x16 LCD with PCF8574 chip I2C, i tried all address in data scheet, i am using your same board F401RE but the device is not ready and led2 on board never switch on. I make your same connection on nucleo board SCL and SDA pin on PB8/PB9 respectly. The strange thing is that on arduino i have no issue and i can send some word on LCD like "hello word" ect. How is possible.
already understand and get working, but something fishy happened, when it calculates the second, until 9 should be 10. but it becomes 16. the seconds count is correct until 60. just the numbering is wrong, i got until 90. Do you know about this?
Yes, that's BCD count.. so there are 4 bits for seconds and other 3 bits for 10s of seconds. 000 1001 = 9 decimal = 9 sec 001 0000 = 16 decimal = 10 sec
tnx for Video. I want to sense data from SHT31 and send to one TRX modul(CC1101) and then from that to another TRX modul. I have write 2 Projekt seperatly. but when i add one to another , my sensor dont send data. I think , There ist Problem here: HAL_I2C_Master_Receive(&hi2c3, 0x44
Hey, great video .. I was wondering how to connect your code from the video with the LCD via I2C on the stm32 discovery with this board.. i am trying without success, can you please help me?
Thanks a great Deal for this video. It helped me alot after several manhours of failed debugging. Turns out for the Nucleo F410RB, STM32CubeMX initializes the wrong pins (PB6 and 7) instead of PB8/9 as i discovered by help of your video.
This comment saved me!!!! Thank you!!!
Much better explained than recent Stm series but please do full ones. We want registers explained too. Thanks. Keep good work.
the best embedded teacher ever!!!
:)
Great video series, btw at 2:11 you can select from left peripherals i2c1 to enabled and cubemx will enable required pins
I will be very happy if you make another series for STM32 :)
Hi..I want to communicate between two stm32 of different cores via I2C, lets say between F0 and F7.F0 would be slave and F7 master.The idea is when user button on F7 board is pressed ,the control will shift to F0..but i don't know how to give a slave address to my F0 and which registers to use for address..So how can i do that and how to make sure that address is not already in use.
Good job, very helpful, many thanks.
Cheers
I did this for the STM32F446RE board, the LED2 didn't turn on, the address is the same so its a bit weird, I think maybe my board is defective. any suggestions?
What other device have you used with which the stm32 is connected? I am trying to interface an arduino but it doesn't work.
great video from great man . Thank you Sir
Very helpful sir thanks👍👍
Thanks Mohammed! Spot on!
The HAL documentation says that you need to shift the device address by 1 to the left before calling the interface. Is there a reason you've not done that? Also wouldn't the device address be 0xD1 when you are reading from it since the RW bit is now 1.
HPB1980
Hi,
The reason datasheet suggests shift to the left by 1 is because HAL library includes Rd/Wr bit with the address.
In my case, I included that directly;
Address with the Rd/Wr bit is 0xD0 = 1101 0000
Without Rd/Wr bit is 01101000 = 0x68
Hope this helps
Got it. Thank you. Wouldn't the read address be 0xD1 then since the RW bit is 1 when reading from the device.
HPB1980
That's right.. the HAL library receive function does that automatically.
If anyone else is stuck on the 1101000 to D0 conversion like I was (or I'm just stupid hehe). 1101 Binary is "D" in hex and 0000 is "0" in hex. Gotta split it into pairs of 4 :o
Hi, i using 2x16 LCD with PCF8574 chip I2C, i tried all address in data scheet, i am using your same board F401RE but the device is not ready and led2 on board never switch on. I make your same connection on nucleo board SCL and SDA pin on PB8/PB9 respectly. The strange thing is that on arduino i have no issue and i can send some word on LCD like "hello word" ect. How is possible.
already understand and get working, but something fishy happened, when it calculates the second, until 9 should be 10. but it becomes 16. the seconds count is correct until 60. just the numbering is wrong, i got until 90. Do you know about this?
Yes, that's BCD count.. so there are 4 bits for seconds and other 3 bits for 10s of seconds.
000 1001 = 9 decimal = 9 sec
001 0000 = 16 decimal = 10 sec
Good job 👍
tnx for Video. I want to sense data from SHT31 and send to one TRX modul(CC1101) and then from that to another TRX modul. I have write 2 Projekt seperatly. but when i add one to another , my sensor dont send data. I think , There ist Problem here: HAL_I2C_Master_Receive(&hi2c3, 0x44
Hi,
I don't have enough details to attempt to help with this
Thanks man🙏🏻
thanks
Hey, great video .. I was wondering how to connect your code from the video with the LCD via I2C on the stm32 discovery with this board.. i am trying without success, can you please help me?
You forgot to change your I2C - ready test back to 0xD0 from 0x32
i agree
What's the addres for a I2C interface PCF8574T?
Most likely 0x40
hello mohamed ,thanks for your tutorials i want to make I2C between the stm32 as master n ?؟two arduinos as slave can you help me
Mahmoud Elshall
Hi Mahmoud,
This is something that I definitely plan to make a tutorial about soon
Mahmoud Elshall I hope it will be soon, 😊
Thanks