STM32F4 DISC1 CAN and USB peripheral together doesnt work - stm32

Hi I have a problem with stm32f4 disc1.
I can transmit over USB( USB_FS_CDC) message using CDC_Transmit and i can send CAN message but dont get interrupt for receiving CAN message. Interrupt occurs that can message is received only when i dont initialize USB_CDC.
Hi is it possible to use in the same time can and USB CDC because i need to receive message from can and then transmit over usb to PC?

Related

Can transmit and receive with LoRa both on single uController?

I want to send and receive data with two Lora module but I have only one STM32l4 nucleo board. Is it possible to connect both transmitter and receiver Lora module to this board and have a communication between them?
Yes it should be possible to have both a transmitter and receiver connected to a single MCU. It mostly depends on the availability of pins.
I don't know why you would want to do that as the transceivers are both transmit and receive capable. Such as the Semtech sx1276.

How Can I send AT commands to GPS module connected to a raspberry pi

My GPS module doesn't automatically turn on its GPS to receive data. The module uses AT commands to turn on GPS and the the GPS shuts down when you remove it from its power source.
The problem is I can turn on the GPS with PUTTY serial monitor when connected directly to my laptop for testing, but I don't know how to turn it on when connected to my raspberry pi because I don't know how to send the AT command through the raspberry pi to power it up.
Is there a way i can send AT commands to a connected device on my raspberry
I have tried the cu method but it doesn't seem to work as I receive no response when I input the AT code
So if I understand it correctly, you can connect the GPS module to your laptop directly and send the AT commands to it but, you are unable to do the same with your RPi.
Think of it like this, how is the computer being able to send the AT commands? Through a UART right? So that means you need a UART like connection between the 2 devices to be able to send AT commands.
Now, lets just replace the computer with the RPi, again you would need a UART connection between the GPS module and the RPi module, lets say a simple RS232 connectivity. Once you have this connection established, you will have to program your RPi to send the appropriate commands to the GPS modem via this connection. So probably what you need to google now is "RS232 communication using RPi". And of course you will need the Tx and Rx connections to be proper between the two devices.

How to upload an Arduino source code to a Lilypad Arduino?

I bought a Lilypad Arduino, for which an FTDI socket is required to connect to my PC. The first socket I tried on didn't power up the Arduino, because of some hardware damage. Thus, I got another socket, but with 4 female pins (Vcc, Gnd, TX, RX), unlike the previous one that had 6 male pins. Let's call the second socket as X. With X, the Lilypad is getting powered up through USB cable. Then, when I tried to upload my source code the first time, it started working.
But when I uploaded it some time later, an error called 'programmer is not responding' occurs always, which I'm unable to resolve.
What should I do?
To program an Arduino (and Arduino-compatibles), you need an FTDI adapter that has an RTS pin, as well as the Vcc, Gnd, TX, and RX pins.
The RTS pin connected to the reset circuit on the Arduino, putting the bootloader into programming mode for a few seconds.
You may be able to get it to work by resetting the Lilypad with it's reset button, then upload your sketch within a few seconds after the reset. Alternatively, or for the least hassle, get an FTDI adapter with all the needed signals. I recommend Adafruit's FTDI Friend.

How to receive notifications of packet delievery status

I am now writing a program which should be able to dynamically select and switch 802.11 channels. Multiple threads can use a shared 802.11 radio. The goal is to let a thread lock the radio before switching channel, and then transmit one data packet, finally, unlock the radio after the data packet has been successfully transmitted out of the 802.11 NIC or dropped permanently.
But I can't find a way to know if a data packet has been transmitted out of the NIC card or it is still somewhere in the host. I am programming in C on Ubuntu. I use UDP socket to send the data packet. A successful return from "sendto" doesn't indicate that the data packet has been successful transmitted out of the hardware.
Could anyone point out a way to receive notifications of packet delivery status from 802.11? To sum up, I want to receive notifications when a data packet has been transmitted out of the NIC for broadcasting mode, and when a data packet has been successfully received by the other end or has been permanently dropped for unicast mode.
Any answer will be appreciated!

MATLAB USB HID data receive

Is there a way to receive the data sent over USB to PC using HID protocol in MATLAB? I tried the host hid receiver block found in STM32 blockset in Simulink but it gives an error saying that STM32 device not found so I guess that blockset is spesific for a STM32 device.
Under Linux, you can read from /dev/input/mice. It covers position data and clicks. You might need to adjust the reading privileges of the device file.