Show Posts
|
|
Pages: [1] 2 3 4
|
|
2
|
Using Arduino / Networking, Protocols, and Devices / Re: Xbee Explorer Dongle or Regulated problem?
|
on: February 10, 2011, 10:18:33 am
|
Guys, i solved the problem already. My receiver end is able to show the values that i wanted using the serial monitor. However,i encountered another problem. The delay is set at 400, means every 0.4 secs data are rolling in. But at times, the serial monitor shows data coming in at like 0.1 secs or faster. I need to press the reset button when this happens and data comes in at 0.4 secs again. I do not know what is the cause. Can anyone help? Is it poor contact or something? 
|
|
|
|
|
3
|
Using Arduino / Networking, Protocols, and Devices / Xbee Explorer Dongle or Regulated problem?
|
on: February 09, 2011, 11:47:19 am
|
Guys, i am using an Arduino Pro Mini 5V/16MHz. I use one analog output and four digital outputs. I wrote my sketch on the Arduino IDE and upload my sketch on the Arduino Pro Mini using the 5V FTDI Breakout Board via the six pin headers. When i open serial monitor, i get the correct values. The values that i wanted. However, when i disconnect the 5V FTDI Breakout Board and connect the Xbee Explorer Regulated to my Pro Mini to transmit my data wirelessly, i get incorrect data on the receiver end when i open serial monitor.  My receiver end consists of a Xbee Explorer Dongle+chipped Xbee. I checked that the two chipped Xbees that i m using are working well. Guys, do you all know what is the problem?  Appreciate your help. Thanks in advance.
|
|
|
|
|
4
|
Forum 2005-2010 (read only) / Syntax & Programs / Re: Problem with displaying data on the serial monitor
|
on: December 07, 2010, 10:23:15 am
|
|
If you are saying that serial comms used to work with the shield on, but now it doesn't, then I have no idea why it should have stopped working.
Things only stop working if something changes or something breaks. If nothing has changed then something has broken.
Yup, this is wad i meant...i was wondering if the shield is spoilt...or have i short-circuit the shield or something?
|
|
|
|
|
6
|
Forum 2005-2010 (read only) / Syntax & Programs / Problem with displaying data on the serial monitor
|
on: December 07, 2010, 06:52:48 am
|
|
Hey peeps, today i encounter a very weird problem. When i upload a sketch on the Ardunio IDE and open my serial monitor, i got the correct voltage values that i want. (Circuitry on breadboard to get the values)
However, when i put the shield + Xbee to transmit the values, the serial monitor suddenly stop displaying data...Does anyone knows what is the problem? :-?
It used to work previously and i can even get the same values that is transmitted onto the receiver end of the serial monitor on another computer.
Both Xbee are configured correctly with the X-CTU software already..
Did i accidentally spoil the shield? :'(
|
|
|
|
|
9
|
Forum 2005-2010 (read only) / Syntax & Programs / Re: Serial monitor question
|
on: November 22, 2010, 12:07:51 pm
|
Cause i want display 2 waveforms on Labview (Graphical Programming).... O ya, sorry i made a mistake....Serial.print(", ") command will print the comma....  PaulS, if my voltage and temperature values keep changing, can i still stick to those commands to display them on the same line of the serial monitor? 
|
|
|
|
|
10
|
Forum 2005-2010 (read only) / Syntax & Programs / Re: Serial monitor question
|
on: November 22, 2010, 11:37:41 am
|
Serial.print(voltage); Serial.print(", "); Serial.println(celcius, DEC); Those commands above will do this right? 1.854365775829.52 1.854365775829.52 1.854365775829.52 1.854365775829.52 I will try that tmr n let u guys know if it works Sorry PaulS for the misunderstanding 
|
|
|
|
|
11
|
Forum 2005-2010 (read only) / Syntax & Programs / Re: Serial monitor question
|
on: November 22, 2010, 11:24:04 am
|
Umm no....i dont think u got wad i meant....i m using two analog inputs...so my voltage and temperature readings on the serial monitor will keep changing i used Serial.println(voltage, DEC); followed by Serial.println(celcius); I get this on the serial monitor 1.8543657758 29.52 1.8543657758 29.52 These values will keep changing I want get this on my serial monitor: 1.854365775829.52 1.854365775829.52 i want them to be on the same line...how should i do it? 
|
|
|
|
|
12
|
Forum 2005-2010 (read only) / Syntax & Programs / Re: Serial monitor question
|
on: November 22, 2010, 11:09:12 am
|
wow very nice answers...i know how to use the Serial.println() and Serial.print() commands. I want to print: 1.854365775829.52 1.854365775829.52 1.854365775829.52 with no spaces on the serial monitor. How do i do that? If i use these commands below, Serial.print(valOne); Serial.print(", "); Serial.println(valTwo); I will not get what i want... 
|
|
|
|
|
13
|
Forum 2005-2010 (read only) / Syntax & Programs / Serial monitor question
|
on: November 22, 2010, 04:52:57 am
|
Guys, my question is similar to liabilityquek's post. I understand that Serial.println() command allows one to print data on the serial monitor. Take for instance, when i used 2 analog inputs, my serial monitor looks like this : 1.8543657758 29.52 1.8543657758 29.52 I need to use two Serial.println() commands to display the above statements on serial monitor. I used Serial println (voltage, DEC); and Serial println (Celcius); However if i want my serial monitor to look something like this : 1.854365775829.52 1.854365775829.52 1.854365775829.52 That is like printing both voltage and celcius on the same line of the serial monitor. Is that possible? Can one Serial.println( ) do the job? Thanks peeps. Awaiting and appreciate your replies 
|
|
|
|
|
14
|
Forum 2005-2010 (read only) / Syntax & Programs / Re: How do i combine two Arduino sketches?
|
on: November 17, 2010, 02:47:39 am
|
Thank you Grumpy_Mike. I appreciate your prompt replies to my posts. Thank you lloyddean for making the effort to alter my disorganised program. Anyway, if i put a delay into my program, do i put it right at the end? Also, the altered program that lloyddean posted....does it function the same way as my old program?  Thank you guys 
|
|
|
|
|
15
|
Forum 2005-2010 (read only) / Syntax & Programs / Re: How do i combine two Arduino sketches?
|
on: November 16, 2010, 02:00:42 pm
|
Thanks for the reply.  Do u mean: #define SENSOR 0 // select the input pin for // the LM335A temperature sensor float val = 0; float val2 = 0; float deg = 0; float celcius = 0; void setup( ) { Serial.begin (9600); } void loop( ) { float voltage = 0; int sensorValue = analogRead (A0); voltage = sensorValue * 0.0048; // code width(sensitivity) = 5 / 210 = 4.8mV Serial.print("The voltage is "); Serial.println (voltage, DEC); val = analogRead(SENSOR); val2 = val * 0.00489; // take SENSOR value and multiply it by 4.89mV // and store value to val2 deg = val2 * 100; // multiply by 100 to get degrees in K celcius = deg - 273.15; // subtract absolute zero to get degrees celcius Serial.print("The temperature reading is "); Serial.println(celcius); } Why do u not need the delay anymore? How will the serial monitor looked like? 
|
|
|
|
|