Is it possible to directly connect Arduino Mini to PC? - usb

I have an Arduino Pro Mini and a USB cable with just wires from one side. Is it possible to connect these wires directly with Arduino? I mean, +Data to Rx, -Data to Tx, +5v to one of the numbered pins and ground to GND.

No, in fact you could damage your Arduino doing this.
The RX and TX pins are for Serial (which run at higher voltages than 5volts)
Your best option would be to buy a USB to Serial convetor and then use a MAX232 chip (it is a chip that converts TTL logic (5volts) to RS232 (3 to -25 volts).
Or you could try using the v-usb library. Google v-usb online.
Hope this helps.

Yes, but not as you think, there is a raw voltage and regulated voltage but why run the risk of wiring incorrectly.
The best is use USB device between FTDI.
Here is a simple pin connection to make programming easier in photos. (quality of photos may not be best but you get the idea from them) I don't show how I add the blue to the pins but that is shrink tubing heated.
This makes easier programming of your Arduino this can be attached to a programmer quickly and effectively.
You can get this from Sparkfun for very cheap FTDI

Related

STM32 boot loader

I'm learning about embedded systems and have an idea about one small project and I want to use Cortex M0+ based MCU STM32G081KBT6. I saw a lot of tutorials with this MCU type, but all of them are based on developer board and with them it is very simple to upload code with USB cable. I want to make my custom PCB for this. So my question is what I have to do so I can upload my code to this microcontroller?
From a datasheet I think I have to use SWDIO (PA13) and SWCLK(PA14) ports for Boot, but if someone can help me do I have to use also some resistors, can I make it USB to wire transfer with this, or I have to use some external device to make it possible? Or there is some easier and better solution to upload code from my laptop to microcontroller?
Thanks for the replies.
There two main options:
SWD
Implement an SWD programming connector. Basically the pins GND, SWDIO, SWCLK and preferably 3.3V are made available. No resisters are needed. You can fit a 4 pin header, an official 10 pin SWD connector or just 4 pads (for connecting using an adapter with pogo pins).
This option requires an SWD debug adapter like ST-Link or J-Link. In addition to uploading firmware, this option supports debugging.
USART
Make the USART (RX, TX) pins plus GND and 3.3V available on the board. This option requires a USB-to-serial adapter.
It's also possible to use I2C or SPI instead, though there are no standard solutions for connecting to your board that I'm aware of.
USB isn't an option for this particular chip. It is supported on many of the more expensive STM32 chips though.
I strongly recommend the first option. It is far more versatile than the other options. And an ST-Link adapter isn't expensive.
Details regarding the bootloader capabilities and pins:
https://www.st.com/resource/en/application_note/cd00167594-stm32-microcontroller-system-memory-boot-mode-stmicroelectronics.pdf

embedding code into MSP430 without JTAG

I am a newbie in this subject and want to learn how to embed codes into MSP430.
I have a breakout board MSP430-H5438 and I am not using JTAG interface.
I have the IAR generated codes (hex files) ready (ADC, SPI interfaces), however I could not load them into the IC.
I am using a USB-UART bridge to connect device to PC, BSL scripter for software, but there is no result.
Is it a wrong way to connect MSP430 to PC without JTAG interface? Am I running in circles here?
Thanks in advance.
BSL should work but you need to connect not only the TX and RX but also you need to have DTR connected to RST and RTS to TEST. If your USB-UART interface only has TX and RX (which is often the case) then it will not work with BSL.
Note that the MCU on that board supports not only the regular (and expensive) JTAG but also the newer SBW interface. This means you can get the $4.30 Launcphad and program your board using the programmer that is included on the Launchpad. This will let you do anything you can do over the regular JTAG and is highly recommended over BSL since it will give you hardware debugging functionality. And the Launchpad can be useful on its own too.

How to program on this arm

I have this samsung chip on a board (samsung s3c2510a) and I want to program to it via some method. However, I don't have a jtag reader on me and this board has a usb port. Is there any way to tell if I can program to the chip via this usb port? I ripped the board off a color laser printer by samsung and the board also has an ethernet connection.
Also, this board has 4 pins called "cn4 debug". Would this be of any use?
Here is a pic: http://imageshack.us/photo/my-images/262/img20120527120306.jpg/
Thanks,
Rohit
I doubt programing this board would even be posible. You could check if there is any software that is used to update the board (from the manufactuter) and try to reverse the protocol. You would also need to figure out the format of the firmware file. There is a lot of good stuff on hacking router firmware that may help. You should be able to find some mailing list to ask for help on.
For any device to be programmed over USB or indeed any port that is not part of the on-chip programming/debug architecture requires software/firmware supporting that port to be present on teh chip already. Some microcontrollers include ROM based primary bootloader code for this purpose. The S2C2510A has no such bootloader. But if the board already has software on it, part of it may indeed be a bootloader. However unless you can get information on the protocol used, you do not really have much hope.
A picture of the board does not really help; what you need is a full data sheet and/or schematic. You'll also want the data sheet and user reference manual for the chip itself. You don't really have much hope of making sense of this board without them. The board does not look like a development board to me, so board specific information may not be available.
CN4 merely means "Connector Number 4". Having just four pins it is likely that it is merely a connecting to the Console UART - a minimal low speed serial data peripheral on the S3C2510A.

Arduino project using infrared sensor and usb communication

I am planning on doing a small arduino project and would like to know if what I'm thinking would work with a regular arduino board. I'm thinking of buying an Arduino Uno for my project, along with an IR LED and an IR sensor. So here's what I want to go with this:
I want to point the LED towards the sensor, so that the sensor is always detecting light. Then', I'll start "cutting" that light (say, with with my hand) several times. I want the arduino program to time the intervals between the times the light is "cut" and send these times to my computer via USB, so I can process this data.
I've seen many people talk about serial communication between an arduino board and a computer, but I'm not sure how that works. Will it use the same usb connector I use to upload programs to the board, or do I have to buy anything else?
EDIT: tl;dr: I guess my question, in the end, is twofold:
1) Am I able to "talk" to my computer using the built-in USB connector on the board, or is that used solely for uploading programs and I need to buy another one? and
2) Is this project feasible with an Arduino Uno board?
Thanks for the help!
Yes, your project is very feasible.
You use the built in USB connector to both program the device and communicate with it. Check out some examples on the Serial Reference Page
For reading the sensor, you'll want to use either a digital or analog input. For a digital input, you'll likely have to external components to control the light threshold, but it will provide a simple yes or no if something is in front of it. With an analog input, you can use a threshold in code to determine when your hand passes.
Timing can either be done on device with the Millis() function or on the connected computer.

Use of GPS chipset

I'm new to the world of GPS. Please help me understand the following:
1) Why GPS chip is required? If the GPS antenna is enough to transmit and receive data, any normal processor could do the decoding of the received GPS data.
2) Does NaviLink 6.0 has its own GPS stack? Doesn't Android has its own GPS stack?
3) NaviLink 6.0 integrates A-GPS, Bluetooth 2.1, FM Tx/Rx on a single chip. Why do you require a chip for bluetooth for FM and Bluetooth? Is FM antenna not enough? Is a separate chip required for Bluetooth too?
it's possible, and it's called "Software GPS" (there is even an open source project)
however, the CPU resources required are really big, and therefore its not really an option for hand-held mobile devices.
also, the sampling rate need to be very high, ad you need A/D converter, which also complicate things