Search the Community
Showing results for tags 'String'.
-
Hi there, first of all sorry but I am a greenhorn in programming a µController :-/ I set myself a new goal that I program a tiny tool to measurer timings of a self made shutter electronic for a camera. For this I would like to send a String by pushing button1 at my MSP430G2553 LaunchPad. The string should be sending via USB connection to PC and again to another USB Port. The hardware at the end of the second USB Port will drive a solenoid. The primary purpose is to measure the delay between sending at the LaunchPad and receiving the driver signal of the solenoid driver.
-
on MSP430G2553 mounted on launchpad I have a problem with converting an integer to a String: uint8_t x=10; uint8_t y=10; String xx = String(x,DEC); String yy = String(y,DEC); Serial.println (xx); Serial.println (yy); with Energia Vers 0101E0012 the result is 10 for xx and 10 for yy but i will to use Energia V17 to use LMP4 mode . the result is garbage for the two converted value --> xxx (three characters) then CR then xxx(garbage three characters) the other problem with Energia V 18 , i can not reprogram the chip (on Windows 9) error is : unable to find a devic
-
on MSP430G2553 mounted on launchpad I have a problem with converting an integer to a String: uint8_t x=10; uint8_t y=10; String xx = String(x,DEC); String yy = String(y,DEC); Serial.println (xx); Serial.println (yy); with Energia Vers 0101E0012 the result is 10 for xx and 10 for yy but i will to use Energia V17 to use LMP4 mode . the result is garbage for the two converted value --> xxx (three characters) then CR then xxx(garbage three characters) the other problem with Energia V 18 , i can not reprogram the chip (on Windows 9) error is : unable to find a devic
-
I am running an MSP-EXP430G2 Lauchpad with an MSP430G2553 on Windows 7. The following code: ============================ #include <IRremote.h> String st; void setup() { Serial.begin(9600); st=String(); } void loop() { st=st+'2'; Serial.println(st); delay(200); } =============== produces following output: 2 22 222 2222 22222 222222 2222222 22222222 222222222 2222222222 22222222222 222222222222 2222222222222 22222222222222 222222222222222 2222222222222222 22222222222222222 222222222222222222 2222222222222222222 2 22 222 2222 ..... After a string length of
-
char final[6]; sprintf(final, "%.3f",current); Serial.println(final); When I put this code to calculate it prints only the "%.3f" I know floating point is not good to use for MSP430, but I do need the decimal places for my calculated results and need to convert to string pass on java socket. Or Can someone introduce me the fixed point calculation? many thanks!
-
hello i am using TM4c123GXL. i am facing problem to Read the string on the Serial Port. Please give me idea ..how i can get my goal.... the function Serial.Read() return the integer .... i want to get the string ...how is this possible Thank you...