STM32 Send and Receive Data to PC without UART || USB COM PORT || Bluepill

  Рет қаралды 111,003

ControllersTech

ControllersTech

Күн бұрын

Purchase the Products shown in this video from :: controllerstech.store
________________________________________________________________________________________
Download the drivers for win 7, and 8 from www.st.com/en/development-too...
To download the code and for more information goto controllerstech.com/send-and-...
Check out more VIDEO on USB with STM32 • STM32 USB
________________________________________________________________________________________
****** SUPPORT US BY DONATING*****
paypal.me/controllertech
******Join the Membership******
/ @controllerstech
Join the Discord Server / discord
Join the Telegram Group t.me/controllerstechdiscuss
Follow me on Instagram / controllerstech
For more info, visit www.controllerstech.com

Пікірлер: 183
@malgailany
@malgailany 3 жыл бұрын
Clear, informative, and well-executed Video. Probably, moving the pointer back to point to the beginning of the buffer after the transmission will also solve the problem of having the old data in the receive buffer. Thank you!
@idanderi1970
@idanderi1970 4 ай бұрын
You are a wonderful human being, this is my favorite video on the internet now
@gunterotte
@gunterotte 3 жыл бұрын
How fast can you send such data to the PC? So what is the virtual baud rate? I'm using the Teensy 4.0 for a similar function, and there it is operating at full USB 2.0 speed. I wonder if ST32 can achieve the same. The reason why I ask is that I want to output debug code to the PC in time critical code, and anything lower than 2MBaud is slowing down the code too much to operate. Thanks!
@prasoft2999
@prasoft2999 3 жыл бұрын
Thank you sir, your videos on stm32 are very useful in learning it.
@noweare1
@noweare1 3 жыл бұрын
I wonder why on the PC (Host) side we are still limited by serial protocols even though the host has full capability for full speed usb.
@mirkacb
@mirkacb 2 жыл бұрын
Hello, thank you for this video. I have a question. What happens if you restart the PC and the board remains connected? Can you still see the device in device manager? Since mine shows the USB descriptor request failed. If I plug it out and plug it back in again it works fine. But I have to do that every time I restart the PC. Do you have any advice on this? How does your device behave? Thanks!
@technics6215
@technics6215 10 ай бұрын
Setting byte after last one would be enough, no need to memset whole buffer. Just read it until '\0'. This is only one thing that that could be improved that I was able to catch in ControllersTech videos after few years of watching. You are awesome!
@filipstojanovicmechanicale9265
@filipstojanovicmechanicale9265 7 ай бұрын
Would it be faster than memseting all buffer?
@DereC519
@DereC519 Жыл бұрын
I get an error that #includes (usb content) didnt work; any help? Thought libraries should all be imported by now
@Swabey89
@Swabey89 2 жыл бұрын
Good video, well explained and straight to the point. Thank you
@user-uh2lf1hn8d
@user-uh2lf1hn8d Жыл бұрын
hi PLS HELP When I receive data i got only first char. I mean that when i print my buffRX as a string or even as char (buffRX[0] or buffRX[1]) i got only last char of string that i receive from PC///// PLS HELP
@nupuravartak8211
@nupuravartak8211 3 жыл бұрын
hello,..i am having a "driver error" in the devices for connected usb...can you please tell how to fix it??
@ferdinvivian9336
@ferdinvivian9336 Жыл бұрын
Sir How the data is received outside the While loop. U r not enabling any Interrupt or DMA. How it is possible
@thecarlos407
@thecarlos407 Жыл бұрын
Very good video, but I'm having some issues, my buffer only receives the last character sent, and stores it in the first section of the buffer array
@franckciccio8032
@franckciccio8032 2 жыл бұрын
Hi, on my computer , on debugging, it doesn't transmit because it return USBD_BUSY, does someone have the same problem?
@MegaYucca
@MegaYucca 10 ай бұрын
Thank You very much for this video. Your example is working on My side too.
@yusufortaca3555
@yusufortaca3555 3 жыл бұрын
It was a very nice instructional video. Thanks.
@csigabigaboca1987
@csigabigaboca1987 9 ай бұрын
I don't understand why you need memcpy, why don't you use the contents of Buf directly?
@santoshsah9250
@santoshsah9250 Жыл бұрын
Thank you sir, your videos on stm32 are very useful. Please make a video on bootloader using UART.
@huutung149
@huutung149 Жыл бұрын
On my computer, the notification says USB device is unknown. Does anyone know why?
@Gkvhkbt
@Gkvhkbt 3 жыл бұрын
Very good. Can you show sigma delta ADC for 16-bit measurement?
@I_moh
@I_moh 2 жыл бұрын
Very Nice work, Thank You !
@samimsk8377
@samimsk8377 3 жыл бұрын
Sir, Thank you very much for the useful video :)
@SanelKeys
@SanelKeys 3 жыл бұрын
Thank you very much for useful video!
@mayssemnasri5945
@mayssemnasri5945 Жыл бұрын
Hello, I need this tutorial now, but it doesn't work I am using STM32F446RE. Are they some updates or something that change?
@ControllersTech
@ControllersTech Жыл бұрын
You need to solder the user usb on that board. The default usb you might be using is for the ST Link, and it can't be used as usb host or device.
@usmanhaider4653
@usmanhaider4653 2 жыл бұрын
i am limitted to recevie 64 bytes. after 64 bytes buffer overflows. "*Len" pointer in "static int8_t CDC_Receive_FS(uint8_t* Buf, uint32_t *Len)" overflows when reaches to 64.
@RobertLugg
@RobertLugg 2 жыл бұрын
Did you indeed change the C code shown? It has a hard code value of 64 I think.
@ertugrulkarakulak369
@ertugrulkarakulak369 2 жыл бұрын
Thank you, very helpful video.
@franciscoreis8256
@franciscoreis8256 3 жыл бұрын
Hey, Everything works almost fine. When trying to receive data on my PC, althought the virtual port is detected (COM12) in my case, the serial port wont open when I press "open". Says windows error #5 in docklight. In hercules it says: Serial port COM12 opening error. Any ideas?
@ControllersTech
@ControllersTech 3 жыл бұрын
What board ?
@LiliaTroudi
@LiliaTroudi Жыл бұрын
Hi! I wanted to thank you first for always replying to my questions. I wonder if we do have to configure the baud rate and others in the hercules utility (logic says that no but I am still confused) Thank you
@ControllersTech
@ControllersTech Жыл бұрын
As much as i tested, it works with all the baud rates. So you can set any baud rate im hecules and it should work
@mustafamertsevim5231
@mustafamertsevim5231 2 жыл бұрын
Thank you for the video, i have a question I am using stmf407g and I do not have USB and USB_DEVICE access from pinout and configuration. Could you help me ?
@ControllersTech
@ControllersTech 2 жыл бұрын
Check your device schematics
@ygorkupas5758
@ygorkupas5758 3 жыл бұрын
Thanks for the content!
@akhilkaki6480
@akhilkaki6480 3 жыл бұрын
can you please make a video on OTA for STM32
@estebangabrielcabanillas7582
@estebangabrielcabanillas7582 Жыл бұрын
Hello! When I'm enabling embedded USB DMA on CubeMX, windows does not recognize the USB device. If DMA is disable, everithing works well. I'm using NUCLEO H7 board. Do you have any explanation for this issue? Thanks!
@ControllersTech
@ControllersTech Жыл бұрын
Yes.. watch the MPU series videos in cortex m7 playlist
@thomasperri3294
@thomasperri3294 2 жыл бұрын
hello I do not have a "USB" to choose from in my Cube MX. only USART?
@ControllersTech
@ControllersTech 2 жыл бұрын
What controller is that ?
@basiltabraham3499
@basiltabraham3499 4 ай бұрын
Hey, I use stm32 blackpill with stm32f411ce6u n the problem i face is when the product connected forthe first time via USB c interface it shows up as serial port and after installation on stlink v2 driver it isn't showing or there is no response via USB c n the c port is giving the power and the board turn on
@ControllersTech
@ControllersTech 4 ай бұрын
Just run this example on the board. The USB C port will be detected when the example is running.
@basiltabraham3499
@basiltabraham3499 4 ай бұрын
@@ControllersTech not anymore I brun it
@julianerf4447
@julianerf4447 3 жыл бұрын
How do you download the code in the microcontroller? I'm used to Keil Uvision compiler, but now in the CubeIDE I can't find this option. Do you have to always open the debugger to flash the code? Also, to use the debugger "live expression" to see the buffer, you had to connect the USB port and the STlink at the same time?
@ControllersTech
@ControllersTech 3 жыл бұрын
To download the code, click the run button No you don't need to connect usb cable. Just connect st link that's enough.
@julianerf4447
@julianerf4447 3 жыл бұрын
​@@ControllersTech Thank you very much for answering. Your videos had helped me a lot!
@gustavovisentin1987
@gustavovisentin1987 3 жыл бұрын
@@ControllersTech but if you want to send data from Hercules while you are debbuging, as you are doing in the video, you have to connect both St Link and USB cable. My problem is when I connect both, the USB com port "cannot be open". Hasn't it happened to you?
@user-qw9ch7yo4g
@user-qw9ch7yo4g 2 жыл бұрын
@@gustavovisentin1987 I have the same problem. It's not working when connect both st-link and usb
@Tommy-tx4dx
@Tommy-tx4dx 2 жыл бұрын
Hello I have a question about the Len parameter in the CDC_Receive_FS function. What is it for? and what am i supposed to fill in? can I leave it out?
@ControllersTech
@ControllersTech 2 жыл бұрын
You don't write cdc_receive_fs function, it will be called automatically when the data is received by the controller. Len is the number of bytes received. In the video i am using memcpy function inside the cdc_receive to copy the received data into the desired buffer. The length of the "data to copy" using the memcpy function will be the Len parameter, as that's the total data we are receiving.
@Tommy-tx4dx
@Tommy-tx4dx 2 жыл бұрын
@@ControllersTech thank you!
@user-ff4zp9gs3n
@user-ff4zp9gs3n 4 ай бұрын
i have a doubt....can i transfer and receive file using this USB COM port method...i want to transfer 1KB files from pc to stm32 board, is there any possibility?
@ControllersTech
@ControllersTech 4 ай бұрын
Yes you can.
@industrialautomation1992
@industrialautomation1992 10 ай бұрын
Hi, I'm using STM32F446RE , i did same procedure i didn't get errors in the program but output is not coming
@ControllersTech
@ControllersTech 10 ай бұрын
It won’t work with stlink usb. You need to connect another usb port. And why bother with this ? Nucleo boards have uart connected to the stlink. You can simply use uart2 to send and receive data to computer, without using any additional hardware.
@shubhamsr4675
@shubhamsr4675 2 жыл бұрын
works perfectly until i press reset button. It stops sending the string (have to unplug and plug the usb) . I don't see any stopping condition in the code . can you explain ?
@panteral6179
@panteral6179 3 ай бұрын
did You resolved that issue?
@sinha....
@sinha.... 7 ай бұрын
I am using stm32l152c disco board And after connecting board to pc port no. is not visible.
@ControllersTech
@ControllersTech 7 ай бұрын
It doesn't work for ST link USB ports. Connect to another USB port (user USB) if available.
@brendanhayes-oberst1398
@brendanhayes-oberst1398 2 жыл бұрын
Can the data received from the stm32 be saved to a text file continuously until the code has finished running?
@ControllersTech
@ControllersTech 2 жыл бұрын
Well you have to build an application for the computer to do so. You can use uart to receive data from STM and save that data to the file on your computer
@ajithanandhan7009
@ajithanandhan7009 Жыл бұрын
can i do USB send and Receive in the Keil IDE using registers ?
@ControllersTech
@ControllersTech Жыл бұрын
of course you can.. but it's going to be very complicated.
@prasadelumalai946
@prasadelumalai946 2 жыл бұрын
It was very useful.. I tried out in my black pill board.. worked amazing.. And speed of transmission is USB_ Full speed ❤️.. Loved it..! Thanks.. Now a big bye bye to Arduino 🤣
@pejvaaksalimi2311
@pejvaaksalimi2311 Ай бұрын
Hi. Does it mean that you can send at 480 Mbit/s?
@lonny_breaux
@lonny_breaux 11 ай бұрын
you are master!!!!!😍
@manuelbfhaeschbacher7942
@manuelbfhaeschbacher7942 3 жыл бұрын
Great video. What would be the way to use printf over your USB-solution?
@ControllersTech
@ControllersTech 3 жыл бұрын
Just create some function like print () And inside it send the data like we did in the main function
@tomaszpazdziora4388
@tomaszpazdziora4388 2 жыл бұрын
Very helpful tutorial! But i have a question. How do you debug and transmit data in the same time? Did you connect ST-link and USB in the same time to your bluepill?
@ControllersTech
@ControllersTech 2 жыл бұрын
Yes
@panteral6179
@panteral6179 3 ай бұрын
@@ControllersTech do You have ideas what can be wrong? If I just load project to BluePill, PC recognises com port, but if I going to Debug it, PC can't see any com-port devices
@berk26092
@berk26092 2 жыл бұрын
Hello sir, how can I receive 32-bit integers? I want receive a value like uint32_t value;
@ControllersTech
@ControllersTech 2 жыл бұрын
The data can only be transmitted in ascii format. So convert the integer into string, then transfer, then convert back to integer
@saurabhjha5401
@saurabhjha5401 3 жыл бұрын
How to modify code if we want to send any sensor data in real time cause there I can't make any pointer
@ControllersTech
@ControllersTech 3 жыл бұрын
Instead of "hello world", send your data..
@HazimEng
@HazimEng 2 жыл бұрын
I followed the same steps. but why on stm32f103c8tx the usb does not working " USB device not Recognized"?
@ControllersTech
@ControllersTech 2 жыл бұрын
Make sure the usb cable supports data transfer.. some cables are only made for charging
@adityah4511
@adityah4511 2 жыл бұрын
@@ControllersTech Hy i too have the same issue.. Any ideas ..i have done everything what you said....
@gabrielfienco2531
@gabrielfienco2531 3 жыл бұрын
You gave me a great idea with this video, just one question any language to built a simple custom app and use usb ??
@ControllersTech
@ControllersTech 3 жыл бұрын
I guess .net
@user-dr9eg4tw8m
@user-dr9eg4tw8m 2 жыл бұрын
I run the program and when the computer sends "start", the micro sends "Hello World from USB CDC" but when I debug the program, micro and PC can not send anything anymore and Sending stops and when I go to Live Expressions in the Value field is written "Target not available". what is the problem?
@user-qw9ch7yo4g
@user-qw9ch7yo4g 2 жыл бұрын
I ran into the same problem. Do you have any idea now?
@panteral6179
@panteral6179 3 ай бұрын
did You resolved that issue?@@user-qw9ch7yo4g
@panteral6179
@panteral6179 3 ай бұрын
did You resolved that issue?
@wendan5280
@wendan5280 18 күн бұрын
@@panteral6179 the same problem)
@merveozdas1193
@merveozdas1193 2 жыл бұрын
I couldn't see which COM, my pc shiws it as STM32 ST Link
@ControllersTech
@ControllersTech 2 жыл бұрын
You need to connect the usb cable
@anghao7050
@anghao7050 3 жыл бұрын
how to download STM32 Virtual COM port driver for Win10. I don't see it in the st.com ( only Win 7-8) :( Help me. Thanks!
@ControllersTech
@ControllersTech 3 жыл бұрын
Windows 10 don't need driver
@anghao7050
@anghao7050 3 жыл бұрын
@@ControllersTech thank you.
@brendanhayes-oberst1398
@brendanhayes-oberst1398 2 жыл бұрын
what board are you using? Did you make your own?
@ControllersTech
@ControllersTech 2 жыл бұрын
It's bluepill... Like the title says
@mostafakh5075
@mostafakh5075 3 жыл бұрын
thanks sir, is that possible to tell us more about c programming like what you did in this video? it would helps a lot
@ControllersTech
@ControllersTech 3 жыл бұрын
What c programming ? I merely used 1 function that was available by default. And i explained that too
@rushikeshkumawat1361
@rushikeshkumawat1361 2 жыл бұрын
Sir, if I do the Simple Led blink Program, then how can I check the output? I want to do it without ST link.
@ControllersTech
@ControllersTech 2 жыл бұрын
If you are just getting started, i would advise that you get a STLink or get a nucleo or discovery board, they have st link built in. There are methods where you can upload the code to the bluepill without ST link. But you need to reprogram the bootloader for that. You can search about it.. I personally haven't done it yet.
@rushikeshkumawat1361
@rushikeshkumawat1361 2 жыл бұрын
@@ControllersTech OK sir. I will try to find and do the work.
@kinshuksrivastava7088
@kinshuksrivastava7088 3 жыл бұрын
Tried transmitting simple "hello" string, didn't work. Nothing shows up on the monitor. transmitting data using mbed libraries works fine though. Any idea what might be the problem ? Device: STM32F446RE, OS: Ubuntu 20.04
@ControllersTech
@ControllersTech 3 жыл бұрын
Read the @jacques comment from 1 week before... And what do you mean you can do it using mbed libraries ? Can u share that library.. maybe it could help through the situation
@kinshuksrivastava7088
@kinshuksrivastava7088 3 жыл бұрын
@@ControllersTech oh, so I can't use the same usb port for USB data transfer which is also used STLINK ? I'm able to send and receive data using a single usb cable using mbed.h library (using mbed online compiler). Also while debugging the program (your tutorial), hcdc->Txstate is always zero so CDC_Transmit_FS() always returns usbd_busy. More over, it says can't access memory at some locations for both Tx and Rx buffer.
@ControllersTech
@ControllersTech 3 жыл бұрын
Can u send the link of the library you are talking about..
@kinshuksrivastava7088
@kinshuksrivastava7088 3 жыл бұрын
@@ControllersTech github.com/ARMmbed/mbed-os/blob/master/mbed.h --> mbed online compiler provides mbed library according to the target device selected.
@ControllersTech
@ControllersTech 3 жыл бұрын
I know what mbed is.. you are just pointing me to "what mbed os is" You mentioned earlier that you can use usb functions to send data to the pc. I am asking the library for those usb functions... If you don't understand this, just check the device manager in your computer and see if the board is recognised as a serial device or a virtual com port..
@francosoto4037
@francosoto4037 2 жыл бұрын
hi people! i'm using the same stm32f103c8t6, and i've tested the code as the video and it works, but without the debugger (stlink-v2), anyone knows if there's a problem using usb communication and debugger at the same time? or maybe i could be missing something... from now, thanks
@panteral6179
@panteral6179 3 ай бұрын
did You resolved that issue?
@BoiledEggFace
@BoiledEggFace 2 жыл бұрын
Would this work if I have no HSE Crystal fitted? I was using a nucleo which didn't have one fitted it worked for weeks and now doesn't worried it might be the crystal
@ControllersTech
@ControllersTech 2 жыл бұрын
Nucleo have 1 shared crystal between the stlink and the mcu. So i don't think it's the crystal
@BoiledEggFace
@BoiledEggFace 2 жыл бұрын
@@ControllersTech Thanks so much for getting back to me! It's the NUCLEO-F411RE which appears to have a separate place for it? It really makes no sense as to why it did work in the past. To be sure if there is no HSE, the 48MHz can't be generated and so the USB device won't work as expected?
@ControllersTech
@ControllersTech 2 жыл бұрын
This particular project will never work with nucleo f411. It requires user usb slot and f411 only have stlink usb.
@BoiledEggFace
@BoiledEggFace 2 жыл бұрын
@@ControllersTech I have just used the IO header (CN10) as PA11/PA12 are available at that header. I have then connected the USB D+/D- to those two points. Thanks again
@ControllersTech
@ControllersTech 2 жыл бұрын
I don't know why are u going through all this trouble when u can simply use the uart2, which is routed through the stlink usb itself, but it's upto you anyway. I don't know why it's not working but i would suggest that you try a different usb once. I am sure it's not the clocks.
@alibarakat1056
@alibarakat1056 3 жыл бұрын
Do you upload the code via st link v2 tool ?
@ControllersTech
@ControllersTech 3 жыл бұрын
Yes
@fadi0802
@fadi0802 Жыл бұрын
Excellent video, but my WIN 10 is not recognizing the new virtual port. I have installed the official STM drivers, but no success! Did anyone face the same issue
@panteral6179
@panteral6179 3 ай бұрын
i think i have the same issue, did you resolved that?
@fadi0802
@fadi0802 3 ай бұрын
@@panteral6179 I have solved it yet, but I think about using another library than, that from ST electronics. I will try it next weeks
@kampkrieger
@kampkrieger Жыл бұрын
"And now as I connect it, a new serial device gets detected!" It rymes! Happy Christmas
@PrasannaRoutray97
@PrasannaRoutray97 2 жыл бұрын
Nice!. The data is transmitted in which format? char or hex? What if I send uint8?
@ControllersTech
@ControllersTech 2 жыл бұрын
Whatever you want to send You need to send as characters.
@therealspixycat
@therealspixycat 2 жыл бұрын
@@ControllersTech I receive just a single char on Windows 11 Putty. It looks like the wrong baudrate setting but the baudrate is not applicable/relevant for a virtual com port. Double checked the clock settings and they are identical. Any suggestion?
@PowerAlejandroLegion
@PowerAlejandroLegion 3 жыл бұрын
Thank you!!!
@priyanshshankhdhar1910
@priyanshshankhdhar1910 Жыл бұрын
i have done everything but during debug session it says target not available
@panteral6179
@panteral6179 3 ай бұрын
did You resolved that issue?
@cristianaguada8101
@cristianaguada8101 3 жыл бұрын
Hi, i cant view "buffer" y Expression. What could i do to show it? thanks! Sorry for my English, im Argentian
@ControllersTech
@ControllersTech 3 жыл бұрын
You have to add it there. Add it in the live expression
@cristianaguada8101
@cristianaguada8101 3 жыл бұрын
@@ControllersTech for do that i need to conect the usb-programer, but then, transmission stops working. Computer stops receiving the recurrent message and buffer[] doesnt receive what i send. Do you know what could be wrong? Thanks
@ControllersTech
@ControllersTech 3 жыл бұрын
You saw i did it in the video right.. Just follow what i did
@user-qw9ch7yo4g
@user-qw9ch7yo4g 2 жыл бұрын
@@cristianaguada8101 same problem here. Have you solved the problem?
@cristianaguada8101
@cristianaguada8101 2 жыл бұрын
@@user-qw9ch7yo4g Hi, yep. I bought a new bluepill. My first STM chip was a fake copy.
@itayjc1
@itayjc1 2 жыл бұрын
Are there any STM32 modles that can do this without an extranal resonator?
@ControllersTech
@ControllersTech 2 жыл бұрын
Yes all of them can work with internal clocks. During the cubemx setup, instead of using HSE (High speed external) clock, just use HSI (internal).
@itayjc1
@itayjc1 2 жыл бұрын
@@ControllersTech When I try to use the HSI, I get an error saying "cannot find a solution for some constraints". I am using STM32446RE. Should I maybe buy a different modle to make this work?
@ControllersTech
@ControllersTech 2 жыл бұрын
1. You can use external crystal for 446RE. It will use the one for the ST link on the top. 2. If using the internal clock, the system clock will be limited to certain frequencies, so you can't use whatever you want in this case. 3. This video won't work with 446RE nucleo, unless you have attached one additional USB port ( you can see it below the empty crystal, "user usb"). The USB that you use to load program is the ST-Link, it's not the user port.
@jacquesmonnier7051
@jacquesmonnier7051 3 жыл бұрын
Thank you for all your content; It really helps. I m trying to do the same thing but on a Nucleo L053R8. Im following the same steps but it is not working.
@ControllersTech
@ControllersTech 3 жыл бұрын
Do your board have the USB ? Nucleo boards comes with only 1 USB port by default, and that is used for st link and uart.. You need to attach another USB to your board..
@jacquesmonnier7051
@jacquesmonnier7051 3 жыл бұрын
@@ControllersTech Hello Thanks for the reply. I thought I could use the USB with the STLINK (I am still a beginner in STM32 field). Everything works now ! (I had also a problem with my current cable, It could not send data).
@botak333
@botak333 10 ай бұрын
How about stm32 usb HID sir? Do u have the video how to send and recive data???
@botak333
@botak333 10 ай бұрын
​@ControllersTech
@ControllersTech
@ControllersTech 10 ай бұрын
Check out stm32 usb Playlist in the description of this video.
@botak333
@botak333 10 ай бұрын
@@ControllersTech okk, i want ask question, how to send and recive data from the game sir?? Like ffb, or other sir?? Its must be used API?? Or posible direct input only??
@Andryu_
@Andryu_ 3 жыл бұрын
Hello, thanks a lot it worked for me! Excuse me, how can I pass a simple integer or float stored in a variable, instead of a string?
@ControllersTech
@ControllersTech 3 жыл бұрын
Convert to string and send..
@Andryu_
@Andryu_ 3 жыл бұрын
@@ControllersTech I'm sorry I didn't get it. I have for example int p = 1, how can I convert it to string? Thanks a lot, I'm sorry
@ControllersTech
@ControllersTech 3 жыл бұрын
Use sprintf. It's very basic c function.. Google it if you don't know what it is..
@Andryu_
@Andryu_ 3 жыл бұрын
@@ControllersTech alright I found it and did it, you are very kind sir, thanks a lot you saved me!
@goodwill7643
@goodwill7643 3 жыл бұрын
thank you :)
@skuula
@skuula 3 жыл бұрын
Very nice! Although Im confused about the conversion to uint8_t to match a size_t. I think size_t is uint32_t or something there about.
@Gabu_
@Gabu_ Жыл бұрын
Your comment is already somewhat old, but indeed size_t is "size_type", which expands to "long unsigned int". Having said that, the function was dealing with char type, therefore uint8_t.
@user-fo4zw6xz9o
@user-fo4zw6xz9o 10 ай бұрын
@@Gabu_ his comment maybe was old, but u answer was helped me understand this problem. thank u much
@user-fo4zw6xz9o
@user-fo4zw6xz9o 10 ай бұрын
but if i don't transfer this to uint8_t, can i using it?@@Gabu_
@wendan5280
@wendan5280 18 күн бұрын
Someone met an Error: L6218E?
@fseeletronicos
@fseeletronicos 2 жыл бұрын
My board is not being recognized as COM port. What should I do?
@ControllersTech
@ControllersTech 2 жыл бұрын
Which board ?
@fseeletronicos
@fseeletronicos 2 жыл бұрын
@@ControllersTech Hi. I am using ST32F013C8T6 Blue Pill.
@ControllersTech
@ControllersTech 2 жыл бұрын
Make sure the usb cable do support the data transfer.. cheaper cables are only build for charging
@fseeletronicos
@fseeletronicos 2 жыл бұрын
@@ControllersTech It does support. I am using Windows 10 and the St-link is being recognized but COM port.
@ControllersTech
@ControllersTech 2 жыл бұрын
You have to run the code. Then connect the USB.. now check the device manager
@irinejose
@irinejose 2 жыл бұрын
Hi, the video was very informative. But can you guide me to any link or video for linux, as HW is not available in linux. I used putty, for getting the transmitted data. But cant do anythng to send data to the board. I am very new to this,if someone can help me with some tutorial guide / site, it will be very helpful. And also after debugging, running the code in STM32 CubeIDE it also shows an error like this : libusb: error [udev_hotplug_event] ignoring udev action bind Can anyone please help me on the above also. Any small clue will be appreciated.
@ControllersTech
@ControllersTech 2 жыл бұрын
you can use putty to send the data also. If it's not convenient, look for cutecom.
@ranco801
@ranco801 Жыл бұрын
Thx! ps: USB interrupt must be enabled
@dnyaneshvarsalve2984
@dnyaneshvarsalve2984 2 жыл бұрын
(Edit - IT'S WORKNG NOW)... I am using stm32L475 and I cant see options for usb as shown in video. I can see three options USB DEVICE USB HOST USB_OTG_FS ALL WERE GRAY but when I selected there pins, I can enable USB_OTG_FS . I proceed with it, but in my project I can find any usb_cdc_if.c. Even the USB device folder is not generated.
@ControllersTech
@ControllersTech 2 жыл бұрын
Can u give the full name. I tried it with l475vg and the USB_OTG_FS is not greyed out.. From there you enable the host.. then the USB_HOST option will be available too
@dnyaneshvarsalve2984
@dnyaneshvarsalve2984 2 жыл бұрын
@@ControllersTech I did it today, It was just a matter of different wording, It is working properly now. Thanks for reply
@santojos5580
@santojos5580 3 жыл бұрын
Tutorial 👍
@incxxxx
@incxxxx 18 күн бұрын
How to do it for nucleo F767ZI ???
@ControllersTech
@ControllersTech 18 күн бұрын
Why would you want to use it in a nucleo board ? You can simply use the uart2 to communicate with the computer.
@incxxxx
@incxxxx 18 күн бұрын
@@ControllersTech You could also use uart in case F103C8 but you did not. Besides I want to do it without uart in similar way as you did but I encontered problems.
@ControllersTech
@ControllersTech 18 күн бұрын
No you can't use uart in 103c8, if you do, you need to connect an external hardware to convert the uart data to usb. This was the main reason for the video. The nucleo boards has virtual com port which allows the uart data to display on the serial monitor without the use of an external hardware. Anyway if you insist on using it, you need to connect the usb to the "user usb" port, not the st link. Also make sure that the usb supports data transfer.
@incxxxx
@incxxxx 18 күн бұрын
@@ControllersTech USB_DEVICE and USB_HOST in MXCube are disabled. I did not find the information how to enable them.
@bsbharat0705
@bsbharat0705 3 жыл бұрын
Nice work👍👍
@jiraphonsasomsap1808
@jiraphonsasomsap1808 Жыл бұрын
thx
@crazy4759
@crazy4759 3 жыл бұрын
Mandalorian 😄👍🏻👍🏻
@Andr_e_y
@Andr_e_y 2 жыл бұрын
best
@eslamaboutaleb3482
@eslamaboutaleb3482 3 жыл бұрын
Link of your background also please 😂❤️
@ControllersTech
@ControllersTech 3 жыл бұрын
www.wallpapertip.com/wpic/iTibRxi_mandalorian-wallpaper/
@lilymorgan7932
@lilymorgan7932 3 жыл бұрын
Really nice 👌 😍💋 💝💖❤️
NEXTION GUAGE and PROGRESS BAR || STM32
17:20
ControllersTech
Рет қаралды 15 М.
Heartwarming Unity at School Event #shorts
00:19
Fabiosa Stories
Рет қаралды 17 МЛН
50 YouTubers Fight For $1,000,000
41:27
MrBeast
Рет қаралды 171 МЛН
Now THIS is entertainment! 🤣
00:59
America's Got Talent
Рет қаралды 38 МЛН
STM32 USB CDC HOST and DEVICE || Communicate using USB || HAL
12:41
ControllersTech
Рет қаралды 42 М.
I Melted Wood With Friction
8:44
The Action Lab
Рет қаралды 846 М.
USB COM Ports in C++
35:42
EETechStuff
Рет қаралды 30 М.
STM32 Crash Course (8) - STM32 USB CDC Introduction
54:53
SD CARD using SPI in STM32 || Cube-IDE || File handling || uart
16:42
ControllersTech
Рет қаралды 86 М.
Installing the STM32 USB Bootloader, Easily! [SEE DESCRIPTION]
8:02
Caleb Marting
Рет қаралды 262 М.
Transmit data using UART in STM32 || Poll || Interrupt || DMA
20:34
ControllersTech
Рет қаралды 73 М.
STM32 USB training - 09.1 USB CDC device basic labs
48:02
STMicroelectronics
Рет қаралды 48 М.
Здесь упор в процессор
18:02
Рома, Просто Рома
Рет қаралды 380 М.
Look, this is the 97th generation of the phone?
0:13
Edcers
Рет қаралды 4,3 МЛН
Top 50 Amazon Prime Day 2024 Deals 🤑 (Updated Hourly!!)
12:37
The Deal Guy
Рет қаралды 1,4 МЛН
S24 Ultra and IPhone 14 Pro Max telephoto shooting comparison #shorts
0:15
Photographer Army
Рет қаралды 9 МЛН