hello sir, I have a question I hope you can help me with, there is a K pin in the board, the vendor say it is a PWRKEY pin and it is connected to GND, If sent this command (AT+CPOF) to the board to power it off can I use the PWRKEY to power it back on ? If yes how I can use it ? by putting 3.3 volt from the stm32 to it ? thank you
Hi I'm trying to publish the data directly to the HiveMQ from my STM32F4xx. So, I don't want to use the node js in the project so can you help with how to publish the data to a particular topic from STM32 board with SIM7600.
Hello I'm currently working on a project where I need to interface an STM32F4 microcontroller with a SIM900 module to send TCP/IP data to a server. I was wondering if you have experience with this kind of setup and could share their source code with me. Specifically, I'm looking for any tips or advice on how to properly interface the SIM900 module with the STM32F4, as well as any sample code for sending TCP/IP data to a server. Any help or guidance would be greatly appreciated. Thank you in advance for your time and assistance. Best regards,
hello sir, Great video thank you for sharing your knowledge... sir, can you make a video on " stm32cubeIDE mqtt publish to broker using esp8266 with stm32f103c8t6" please.........
Hi, thank you for your video it really did make it easy for me, but in the commented line that should be used to connect to a broker with user and password, you forgot to add the two quotations for the user and password, just if anyone failed to make it works, I also created a record for the SIM module reply to each command so that I can debug better if it didn't work
This does not work for me. When connected to a serial terminal it does not get past the first AT command. I'm using a SIM7600G-H and Nucleo-F042K6 with the pins remapped. I have confirmed that the hardware setup works with your other video about sending an SMS.
You need to have mobile data available for this test Try with a different sim card It seems like it does not passing from AT+CGREG? AT+CGREG? Gives one of the following response 0,0 - not registered, MT is not currently searching a new operator to register to 0,1 - Registered, home network 0,2 - Searching 0,3 - Registration denied 0,5 - Registered, non-home network Check from a serial terminal what response it gets (0,1 is the one we need)
@@NizarMohideen Thanks for your reply. Actually I only got the response to the first 'AT' by inserting a function that waits for the modem to fully initialise before sending 'AT'. Once the program enters mqttPublish(void) it fails. That is to say, if I run the code exactly as you have presented it, I never get a response from the modem.
Here is the function I included: void waitForModemInitialization(void) { printf("Waiting for modem initialization (PB DONE)... "); int modemReady = 0; while (!modemReady) { // Receive modem output HAL_UART_Receive(&huart2, buffer, sizeof(buffer), 1000); printf("Received line: %s ", buffer); // Check for "PB DONE" message if (strstr((char *)buffer, "PB DONE")) { modemReady = 1; printf("Modem initialized (PB DONE). "); } HAL_Delay(1000); } // Turn off echo SIMTransmit("ATE0 "); // After modem is ready, send the AT command and wait for "OK" int ATisOK = 0; while (!ATisOK) { SIMTransmit("AT "); HAL_Delay(1000); if (strstr((char *)buffer, "OK")) { ATisOK = 1; printf("AT command OK. "); } else { printf("Waiting for AT command response. Buffer: %s ", buffer); } } }
These setup/code are for SIM7500 SIM7600 SIM7800 Series. They use different AT commands for SIM7000 series. For example (to publish) AT+CMQTTPUB for SIM7500 SIM7600 SIM7800 Series AT+SMPUB for SIM7000 series. You can read the data-sheet for that module and use similar algorithm to create codes. Thanks
May be the ADC is slow. Try sending some ordinary numbers If the MQTT broker is slow, try different times when the broker is not busy or use different broker Thanks
@@NizarMohideen okay, it is clear, in fact my problem is that i can connect to public broker like hivemq with the SIM800L, but it still not work with the local mosquitto broker, have you an idea how to fix this problem?
As I shown in the later part of this video, Create a Node JS app and put your credentials (host, port, username, password). Subscribe to your topic and console log the received data.
int comandoA0 = 0xA0; int comandoA1 = 0xA1; int comandoA2 = 0xA2; int comandoA3 = 0xA3; int comando00 = 0x00; int comando01 = 0x01; int comando02 = 0x02; séria normal que lo envíe a través de los comandos AT, así: sendAndCheckAT("AT+CIPSEND ", ">",5000); relé: sprintf(comandoAT, "%s", comandoA0); enviarYComprobarAT(comandoAT, "OK", 1000); HAL_Delay(500);
wow it's so nice description. thanks
Thanks so much for this tutorial Sir. Just out of curiosity, how can one send data from server side to the hardware/device in this case?
hello sir, I have a question I hope you can help me with, there is a K pin in the board, the vendor say it is a PWRKEY pin and it is connected to GND, If sent this command (AT+CPOF) to the board to power it off can I use the PWRKEY to power it back on ? If yes how I can use it ? by putting 3.3 volt from the stm32 to it ?
thank you
Hi I'm trying to publish the data directly to the HiveMQ from my STM32F4xx. So, I don't want to use the node js in the project so can you help with how to publish the data to a particular topic from STM32 board with SIM7600.
Thank you so much indeed. We really appreciate your great effort.
Please Sir can you do this with esp32 with GSM module and hivemq broker.
Hello
I'm currently working on a project where I need to interface an STM32F4 microcontroller with a SIM900 module to send TCP/IP data to a server. I was wondering if you have experience with this kind of setup and could share their source code with me.
Specifically, I'm looking for any tips or advice on how to properly interface the SIM900 module with the STM32F4, as well as any sample code for sending TCP/IP data to a server. Any help or guidance would be greatly appreciated.
Thank you in advance for your time and assistance.
Best regards,
wow it's so great. thanks
Glad you like it!
Nguyễn Văn Đường a có thể giúp e với được k a, a cũng làm theo nhưng đến đoạn node app nó connected xong thì k thầy gửi thông tin về
can i do the same with hiveMQ's broker (instead of test mosquitto broker)
hello sir, Great video
thank you for sharing your knowledge...
sir, can you make a video on " stm32cubeIDE mqtt publish to broker using esp8266 with stm32f103c8t6" please.........
Hi,
thank you for your video it really did make it easy for me, but in the commented line that should be used to connect to a broker with user and password, you forgot to add the two quotations for the user and password, just if anyone failed to make it works, I also created a record for the SIM module reply to each command so that I can debug better if it didn't work
This does not work for me. When connected to a serial terminal it does not get past the first AT command. I'm using a SIM7600G-H and Nucleo-F042K6 with the pins remapped. I have confirmed that the hardware setup works with your other video about sending an SMS.
You need to have mobile data available for this test
Try with a different sim card
It seems like it does not passing from AT+CGREG?
AT+CGREG? Gives one of the following response
0,0 - not registered, MT is not currently searching a new operator to register to
0,1 - Registered, home network
0,2 - Searching
0,3 - Registration denied
0,5 - Registered, non-home network
Check from a serial terminal what response it gets (0,1 is the one we need)
@@NizarMohideen Thanks for your reply. Actually I only got the response to the first 'AT' by inserting a function that waits for the modem to fully initialise before sending 'AT'. Once the program enters mqttPublish(void) it fails. That is to say, if I run the code exactly as you have presented it, I never get a response from the modem.
Here is the function I included:
void waitForModemInitialization(void)
{
printf("Waiting for modem initialization (PB DONE)...
");
int modemReady = 0;
while (!modemReady)
{
// Receive modem output
HAL_UART_Receive(&huart2, buffer, sizeof(buffer), 1000);
printf("Received line: %s
", buffer);
// Check for "PB DONE" message
if (strstr((char *)buffer, "PB DONE"))
{
modemReady = 1;
printf("Modem initialized (PB DONE).
");
}
HAL_Delay(1000);
}
// Turn off echo
SIMTransmit("ATE0
");
// After modem is ready, send the AT command and wait for "OK"
int ATisOK = 0;
while (!ATisOK)
{
SIMTransmit("AT
");
HAL_Delay(1000);
if (strstr((char *)buffer, "OK"))
{
ATisOK = 1;
printf("AT command OK.
");
}
else
{
printf("Waiting for AT command response. Buffer: %s
", buffer);
}
}
}
I have sim7000g, will this code also work for this module?
These setup/code are for SIM7500 SIM7600 SIM7800 Series.
They use different AT commands for SIM7000 series.
For example (to publish)
AT+CMQTTPUB for SIM7500 SIM7600 SIM7800 Series
AT+SMPUB for SIM7000 series.
You can read the data-sheet for that module and use similar algorithm to create codes. Thanks
I did not understand me, I have connected MQTT Brocker with MySQL, now I want to connect the application of mysql phone
I am sorry. I have not done it with a phone
Thanks
Hello, Data is coming to MQTT very slowly. How can I solve this problem?
May be the ADC is slow. Try sending some ordinary numbers
If the MQTT broker is slow, try different times when the broker is not busy
or use different broker
Thanks
Can you send me a code on how to connect an application with the MySQL database, because I tried it before and it did not work for me.
Thanks
Did you mean this one ruclips.net/video/bLbdcjBjhCU/видео.html
I did not understand me, I have connected MQTT Brocker with MySQL, now I want to connect the application of mysql phone
with a NEO-6M pleaseeee
I am sorry I don't have NEO-6M with me at the moment.
what about SIM800L?
The code works for SIM7500 SIM7600 SIM7800 Series. I haven't tested for SIM800 Series. They are using different set of AT commands for SIM800 Series
@@NizarMohideen okay, it is clear, in fact my problem is that i can connect to public broker like hivemq with the SIM800L, but it still not work with the local mosquitto broker, have you an idea how to fix this problem?
Hi Assem,
In my country, we don’t have 2G networks any more. So I can not test with SIM800 Module.
@@NizarMohideen no i mean if there is a configuration that i have to do with the mosquitto broker ?
As I shown in the later part of this video, Create a Node JS app and put your credentials (host, port, username, password). Subscribe to your topic and console log the received data.
hi, can u help me search the apn of Viettel in VietNam?
v-internet
wiki.droam.com/wiki/index.php/Vietnam
@@NizarMohideen thanks
@@NizarMohideen thanks for your video, it is so great.
@@NizarMohideen Can I use this STM32 for receive the message from broker by subscribe the topic "pot/adc/1"?
Yes. You can use the same topic "pot/adc/1" for receiving too.
You can also use a different topic for receiving.
int comandoA0 = 0xA0;
int comandoA1 = 0xA1;
int comandoA2 = 0xA2;
int comandoA3 = 0xA3;
int comando00 = 0x00;
int comando01 = 0x01;
int comando02 = 0x02; séria normal que lo envíe a través de los comandos AT, así: sendAndCheckAT("AT+CIPSEND
", ">",5000);
relé:
sprintf(comandoAT, "%s", comandoA0);
enviarYComprobarAT(comandoAT, "OK", 1000);
HAL_Delay(500);