Show Posts
|
|
Pages: 1 2 [3] 4
|
|
31
|
Using Arduino / Programming Questions / Re: How to detect if the board is connected to PC?
|
on: July 06, 2012, 10:58:57 pm
|
Yes it is.
So if USB is connected and your Arduino starts sending data, your PC will know what to do with it automatically? What is most important, in such a case my Ard program will not start logging data on SD card. I don't care for that sort of argument; I asked a question and it looks like there is no answer to it except but 'no can do'.
|
|
|
|
|
33
|
Using Arduino / Programming Questions / Re: How to detect if the board is connected to PC?
|
on: July 06, 2012, 12:23:49 pm
|
There is an obvious solution for this - like, make PC to send some response when serial bytes arrive, and detect this response with Arduino program; I don't want to use this approach. Why? Can you imaging a generic application that just listens to serial port and handles data regardless of what device is sending it? There is nothing in the USB connection, if that is what you are thinking of, that defines whether the USB connector is receiving power only, or power and there is something on the other end of the serial port.
If USB is connected this is enough for me to know the board is connected to PC and to start serial communications. http://arduino.cc/forum/index.php?topic=107860.0
|
|
|
|
|
34
|
Using Arduino / Programming Questions / How to detect if the board is connected to PC?
|
on: July 06, 2012, 10:49:59 am
|
|
The board is collecting data from some sensor. I want it transmit the data to PC with Serial if it is connected to PC; if there is no connection, it should switch to logging data on SD card. How I could detect programmatically if serial connection is available? I see there is if(serial) function that does the thing, but only for Leonardo. How to achieve something like that with Duemilanove? There is an obvious solution for this - like, make PC to send some response when serial bytes arrive, and detect this response wit Arduino program; I don't want to use this approach. There might be also a possible solution with detecting power voltage, it looks rather unreliable and also requires some hardware arrangements. Are there any programmatically only alternatives?
|
|
|
|
|
35
|
Using Arduino / Programming Questions / Please explain: scope resolution
|
on: June 29, 2012, 11:56:06 am
|
Please explain in a very simple words these lines from some code example: ( http://arduino.cc/forum/index.php/topic,72739.msg546928.html#msg546928 ) #include <SD.h> .... void Setup() { .... SdFile::dateTimeCallback(dateTime); } this is what is confusing me: 1. What is 'SdFile' here and how is it related to SD library? The first line includes SD library; Is SDFile some member or class or whatnot from that library? 2. What exactly means a syntax like 'SdFile::<something>'? can it be replaced with, f.e. 'SDFile.<something>'? I see this used when creating a library, f.e. void Morse::dot() and it just means that dot() is a part of Morse class. But as I understand, this is used only when making library code; when we are using this library in a sketch, we use 'dot' notation, like #include <Morse.h> Morse morse(13); void setup() { } void loop() { morse.dot(); } So I probably understand that the code above passes callback function dateTime to dateTimeCallback(function?), defined within (SD? SDFile?) So what exactly is the need of using SdFile::dateTimeCallback instead of SdFile.dateTimeCallback?
|
|
|
|
|
37
|
Development / Suggestions for the Arduino Project / Re: Board & shields design: lousy. This is just a shame.
|
on: June 24, 2012, 12:20:11 pm
|
The Arduino Ethernet doesn't in fact have a USB connector - it just uses the FTDI pins. The real irritation is the non-standard shield pin separation, but now cranked pins are available you can build on 0.1 matrix boards without problems. Generally it all seems to work.
Will
Will, many "arduinish" boards don't have USB and bulky power connector. My point is that the main, basic and most popular boards were designed even without minimal consideration on how the shield should be attached. It takes a minimal effort to fix it - install mini-USB and shift power connector forward 0.1" and the problem is solved - but it takes time, motivation and some effort. All this was missing. Hence, 'lousy'.
|
|
|
|
|
38
|
Development / Suggestions for the Arduino Project / Board & shields design: lousy. This is just a shame.
|
on: June 22, 2012, 07:53:42 pm
|
 Ard Duemilanove with shield. Whoever came up with 'shields' idea - don't you guys realize this is very lousy design? Change USB connector to USB-mini and power connector to anything less bulky. FEZ Panda has mini-USB, but still the same ugly battery connector which does not allow to connect any shield in a normal way. With design approach like that you will always stay on amateur's level
|
|
|
|
|
41
|
Using Arduino / Sensors / Re: Accelerometer calibration: why it does not work?
|
on: May 20, 2011, 10:28:58 am
|
Obviously not, as I understand it, those formula should work whith _any_ angle? It is saying there 'The method presented here does not require any alignment with gravity' That moment is somewhat unclear to me. What actually means 'axis of sensitivity'? Sensor has 3 axis, and it seems that none of them is required to be aligned with gravity, . Can you please explain it in more details? Oh, I am starting to understand. Rotation effectively eliminates misalignment in vertical plane only, or, rather, in a plane orthogonal to rotation axis  So to make it work for any angle, I must mount it on a cube and take 12 readings. Thanks for a hint, johnwasser!
|
|
|
|
|
42
|
Using Arduino / Sensors / Accelerometer calibration: why it does not work?
|
on: May 20, 2011, 09:59:36 am
|
There is a perfectly simple method for calibrating accelerometer offset and sensitivity using 4-points rotation. The advantage is this method does not depends on the angle between sensor axis and g-axis. http://www.rocklandscientific.com/LinkClick.aspx?fileticket=ph72xW5yI7Y%3D&tabid=68&mid=455The only problem with it is that it does not work. Equations look correct and quite obvious. Does anybody have an idea what is wrong in this method? Details: I simplified calibrating device. Instead of calibrated disks etc. I took a wooden bar with 2 inches sides, 20 inches long, attached metal angle to one side, bent it so that angle's surface is at approx. 30-40degrees related to bar surface and mounted sensor on metal angle surface. Then I took sensor readings (averaged over 1000 values) when turning the bar so that it stands on each of four sides, so this guarantees that measurements were taken on 4 'equally spaced angular positions' with 90 degrees difference. Readings were stable and permanent, and reproducible for each of four sides. I calculated offset values using formula from the above source. The problem is when I re-mounted sensor under a different angle and repeated measurements, I get completely different values for offset and sensitivity. So there is a flaw somewhere in this approach; besides it looks very obvious and simple, but I never met this method described anywhere else, which makes me to suspect there are some reasons why it is not used. Any ideas?
|
|
|
|
|
43
|
Using Arduino / Installation & Troubleshooting / Re: IDE 0022 Serial monitor bug?
|
on: April 24, 2011, 05:29:34 pm
|
Definitely not a cable, just tried another one, brand new with same result. Well, then it is only one reason: my board  Probably some glitch in communication chip. Unfortunately, I don't have another board to compare. But it also proves Arduino serial monitor is not 'resilient' enough compared to every other serial monitors:( Thanks for your time, man!
|
|
|
|
|