Is simultaneous I2C, SPI and USB communication between multiple MSP430s possible? - usb

I have programmed a couple of MSP430x6xx microcontrollers to serve as Master for some I2C slave devices. One of the MSP430s transfer the data received from I2C slaves to a PC using its built in USB Module. I want to extend this to allow all Micro controllers to send data received from their respective I2C slaves to PC using a common bus system. Will it be feasible to use SPI for transferring the data from all MSP430s to a single MSP430 master(already serving as I2C master and USB device simultaneously) which then transfers it to PC? I would appreciate any other suggestions. Thanks

Yes, it is feasible we will have to write your firmware to handle this. You have to identify on the PC somehow from whom SPI/I2C slave it comes the data. So, your main MSP430xxx will do this adding some kind of header to the data saying the id of the slave device.

Related

STM32 acting as both Master and Slave

I am doing a project that has the following components:
STM32F303 Microcontroller
RF Transceiver Module
SPI Line Driver (connected to another primary microcontroller that will be sending/receiving data to the STM32)
The STM32F303 Microcontroller will send commands to the RF module to transmit and receive RF signals (in this first scenario, the STM32F303 will be acting as a Master and the RF Transceiver as a Slave). At the same time, the STM32F303 will also be receiving commands from the primary microcontroller through the SPI Line Driver (in this second scenario, the SPI Line Driver would probably be acting as a Master, while the STM32F303 will be acting as a Slave).
Essentially, I am planning to connect all the MISO/MOSI/SCK pins together, and having two separate CS lines from the STM32F303 Microcontroller which:
A CS line to connect the STM32F303 to the RF Transceiver Module
A separate CS line to connect the STM32F303 to the SPI Line Driver
I have attached a block diagram of what the circuit would look like: Circuit Block Diagram
Is it possible for the STM32F303 Microcontroller to act as a Slave and a Master at the same time as pictured in the diagram above?
Thank you!

can i read and write data to mass storage flash drive by lpc1768 itself alone?

i want use lpc1768 to read and write to usb mass storage device
should i use this Fig30?
Fig30
or this Fig29?
Fig29
for reading and writing to USB MASS STORAGE DEVICE?
I'm asking about hardware design of it
The USB Mass storage device is obviously an USB device and thus your LPC17xx circuit must supply the +5 volts VBUS line. That is figure 31 in the datasheet.
But that also means you have to implement the difficult USB host in the LPC17xx, and SCSI for mass storage.
You could use figure 30 (OTG) if you needed to connect the lpc17xx itself to host like a PC.
Note that SD cards are much simpler to use (via SPI) in Software. And they can be faster: 25 MBit/s instead of 12 MBit/s via USB.

Is there a way to send two udp streams over a xen paravirtualized system taking separate routes over 2 VMs to the same destination computer?

I'm working on my second experiment for my master thesis and my supervisor had some requirements on this experiment and I don't really know how to proceed. Earlier I was thinking that it should be just to forward the packets but now facing the problem hands on I don't know where to begin.
The setup is Computer 1 ->Measurement point->System Under Test->Measurement point-> Computer2
The System Under Test consists of 2 VMs created with the XEN management tool XL.
There is a bridge from computer 1 on the interface "eth0" to "SUT" which is connected to the VM and the same thing on the otherside to computer 2.
I'm going to send 2 UDP streams and compare the timestamps over the measurement points with two servers on computer 2. The streams are going to be separated by port number and keyid for the stream.
My question is how do I make one of the UDP stream take the route through one of the VMs and the other UDP stream to take the other route?

Is I2C master to Master communication possible?

Is it possible for an I2C master device to communicate with another I2C master device ?
Thanks
Yes! As long as it specifies that it can do Multi Master operation, then it can communicate with another Master device. There is a clock synchronization procedure that two masters need to perform. To see how that works, read this PDF, section 4.3.1
I2C FPGA Core from Opencores
Yes it's possible..
But clock synchronization is important part.
Hope u go through above given PDF.

Question about Process communication over USB cable

I have some questions regarding communication over USB cable in Linux, in a Host-Target Device environment.(USB2.0) Please help as we are stuck for the below imiplementation.
We have a host PC connected to a target device (Linux OS) through USB cable.
On the target device we need to spawn 3 or 4 child processes. [Using fork() or some equivalent system call]
All the child process should communicate to the host PC independently though there own source file descriptor and sink file descriptors.
As per our experimentation, one process communicates to the PC at a time then the control is given to another process. But our requirement is for simultaneous communication. We are not sure whether USB driver(2.0/3.0) supports this methodology.
Any pointers regarding this will be helpful.
Thank you.
-AD
As per our experimentation, one process communicates to the PC at a time then the control is given to another process.
This is how computers work. Only one thread at a time has control of a particular CPU - when it blocks for i/o or exhausts its quantum, control is given to another thread.
What do you need simultaneity for that you can't manage with sending data one after the other?
USB is a serial bus protocol with a SINGLE DATA BUS, and this means, what you are looking for is not possible.
But we can have 4 different USB COMMUNICATION PIPES which can provide different paths, but NOT simultaneously.