max voltage level for Rx and Tx:mbed lpc1768 - uart

I have an mbed board with LPC 1768. I want to receive serial data from a zigbee adapter which works on 5V. The voltage beween the Rx Tx pin and ground of the adapter is around 4.99 V. Is it safe to connect it directly to the mbed board Rx, Tx.

Most of the LPC1768 pins are 5V tolerant, so you can connect them to a 5V system without damaging the CPU.
To make sure that the pins in question are indeed 5V tolerant check the data-sheet: http://www.nxp.com/documents/data_sheet/LPC1769_68_67_66_65_64_63.pdf
All pins are listed in section 7.2. You may have to take a look at the mbed schematic to find out which CPU pins are used for your UART.
You also have to make sure that the 5V system will interpret the 3.3V output level of the LPC1768 as logic high levels. Most chips will work fine and interpret anything higher than 2.5V as logic high but there are some exceptions out there that need a higher level. Those won't be damaged but you won't be able to communicate with them without the help of a level-shifter.

Related

ST-LINK could not connect to the target

I'm trying to connect to stm32f401rbt6 with st-link utility.
The MCU has 6 pins connected, as on the image below.
The target is powered by a lab power supply, target GND is connected to the ST-Link GND
When I plug it to the computer, st-link utility says it can't connect.
Tried:
Update ST-Link firmware
Connect under reset is by default, tried all available methods
Checked connectivity for the pins on the image
Connected with the same ST-Link to other MCU
Desoldered the MCU and soldered another one
The issue is still remain. Please suggest what I'm doing wrong, or how to check that my MCU is alive.
I once had similiar issues and i figuered out, that decoupling capacitors were vital. After soldering this onto the pcb, it worked like a charm.
(Similar question: Stm32CubeProgrammer not connecting (no error msg) using ST-LINK V2 dongle and Lora E5 mini board)
You can try the following suggestions. Some ST devices are a lot more sensitive than others when it comes to programming. I have had some ST devices programming without issues and then using practically the same setup on other devices it just won't work.
Place a 22ohm resistor in series on the SWDIO and SWCLK lines. This link suggests only placing it on the SWDIO line but I found that I needed it on the SWCLK line as well. Typical SWD Circuit
For the ST Link Settings try using these:
Reduce the frequency from 4MHz to a lower frequency
Use SWD
Use connect under reset
Don't use an external pull-up on the NRST line.
Make sure that your programming wires between the ST-LINK and the target board are as short as is conveniently possible.
(This one I must stress as being important) Make sure that your processor's ground pins are all connected very closely together (i.e. the tracks between them are as short as possible) and that very importantly your programmer ground is also connected to the same ground pins very closely.- At high programming speeds a thin or long unbalanced (different length) ground track to the processor can cause a problem with some devices.
Whatever you are using to supply power to the processor must have a supply with a similar voltage as the ST-LINK (mine is 3V) - (although I have found that if the processor supply is 3.3V programming seems to still work most of the time.) (Remember the original ST-Link does not supply power only reads the power level.)
A dodgy programming setup can accidentally set the protection to LEVEL 2 bricking your device - so if you have been trying and not getting any further, it might be time to replace your IC.
Prior to changing / erasing a device that had been programmed to LEVEL 1, you might need to first enable the PCROP_RDP option byte. - Once enabled, you should be able to change from LEVEL 1 to LEVEL 0 that will automatically erase the device.
Some people have suggested holding the device in reset until just after pressing the erase button to enable erasing it.
I hope these suggestions help...

Laptop USB port makes 2V 60Hz sine wave on pwm ports?

When I connect my Arduino Mega or Uno to my laptop (HP Pavilion dv6 Windows 7 64 bit) via usb it creates a 2V 60Hz sine wave in the pwm digital pins I am using (2V sine wave when digitalWrite to Low and 5V very noisy pwm when analogWrite is used), and smaller amp sine waves in all the other pins. If I plug either of the boards into a different computer, its totally fine and all the arduino pins give proper 0V or pwm signals. I did not have this problem 2 weeks ago when I ran it, but ran it again today and discovered this problem. The arduino does not appear to have suffered any permanent damage, as it still runs fine on other computers.
The only potentially notable thing I've done in between those two runs was accidentally try to run a motor off an arduino plugged into the laptop that needed more current than the arduino could source ( :$ ). The motor whined but nothing else happened in the second before I unplugged it. Should that be of interest, I only did it on one usb port, and both usb ports are showing this strange sine wave behavior.
Thoughts on what is going on? Is this something I can fix? Is it still safe to program the arduino with my laptop? (Which I can still do, the pins just behave funny until I move it to another computer). I am not able to install software on the other computer (not mine) so cannot do my arduino programming from there.
Thanks!
I had a similar problem between computers and laptops...
My problem was I was running USB power from my computer and a benchtop power supply to some of the digital inputs.
The solution was to cut the trace to isolate USB power from V-in.
This is explained here for Arduino and here for teensy3.1.
....although I didn't measure the signal, there was an overriding noise that limited the PWM output I could achieve...

Where are pin1.0 and pin1.1 on MSP-EXP430F5529LP launchpad for MSP430?

I am looking at the pin-out here: http://www.ti.com/lit/ml/slau536/slau536.pdf and can't find p1.0 and p1.1. Where are they?
The reason (perhaps, stupid) why I started looking for these two pins is because I need to connect RX and TX of a UART somewhere on the launchpad, and p3.3 and p3.4 did not work, and on some loosely related pinouts of other boards such as this: http://energia.nu/Tutorial_DigitalReadSerial.html p1.1 is RXD and p1.2 is TXD (not sure what's the difference between RX and RXD, assuming for now they are the same). So I thought maybe I try these pins and try my luck there? And now I can't find them.
BTW, the pinout shows that p3.3 and p3.4 are UART RX and TX on BoosterPack standard, which I don't have, and on the launchpad these pins are UCA0RXD and UCA0TXT (also, they are apparently UCA0SOMI and UCA0SIMO). I don't know yet what these abbreviations mean, and also, why there are two sets of functions on the same pins and how to switch between them.
My launchpad (in subj) documentation says it supports up to 4 hardware UARTs. Where? And why then is there a UART on booster pack?
Maybe p1.1 and p1.2 are taken for the launchpad's onboard backchannel UART?
If you want to know where every pin goes on this board then you should look at the schematic in the User's Guide. But more importantly, you should get familiar with the datasheet for the microcontroller on the board.
You don't see P1.0 and P1.1 because those pins are not brought out to the booster pack headers (connectors). Those pins are used within the launchpad board for something else. (They are not even UART pins as you hoped.)
P3.3 and P3.4 is the only UART connection that you have available through the booster pack headers. The other UART is on P4.4 and P4.5 and those pins aren't brought out through the headers. So you should probably try to get P3.3 and P3.4 working. Did you download TI's example software for this launchpad? There is probably an example program that uses the UART.
P3.3 and P3.4 are multiplexed as are many GPIO pins on typical microcontrollers. These particular pins can be configured as GPIO, a UART, or an SPI port. SOMI and SIMO are abbreviations related to the SPI function. Your code will have to configure these pins for the UART function. Read the datasheet and study the example software to learn how to do this.
I'm not sure where you saw four UARTs. The microcontroller on this particular launchpad has four serial interfaces but only two of those interfaces are designed for UARTs. The other two serial interfaces can be SPI or I2C.

Is it possible to directly connect Arduino Mini to PC?

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

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.