Show Posts
Pages: [1] 2 3 ... 5
1  Using Arduino / Programming Questions / Re: How to read a register on the 32U4 on: September 25, 2014, 11:30:04 am
Now look at that! It seems the problem is the short delay in my sketch. I measured the voltage on the VBUS pin after disconnecting USB, and it takes about 5 seconds to fall below 1.4V. Then it works as expected (right now with a Leonardo).
Thanks very much for the tip, ardiri, and for trying it in a different setup, robo_maniac.
Maybe I will put a pulldown resistor to the pin to make the transition quicker; when there is USB I do not have to be overly cautious with a couple of mAmps.
2  Using Arduino / Programming Questions / Re: How to read a register on the 32U4 on: September 23, 2014, 04:42:40 pm
I tried this:
const int led = 13;

void setup() {
pinMode (13, OUTPUT);
void loop() {
 if ((USBSTA & (1 << VBUS)) != 0)
  digitalWrite(led, HIGH);
delay (250);
digitalWrite(led, LOW);

and then I put 9 V to VIN and pulled the USB. The LED kept blinking. So does it when I disconnect and just connect 9V through VIN. I have to check the schematics whether the 5V from the voltage regulator somehow sneak to the VUSB-pin, but if not, then there is something not working with that code attempt. Or am I wrong?
#define VBUS 0
does not override/prevent any bitsetting of the MCU, does it? It is just the initial setting, right?!
Good night, all! (Well, Europeans at least...)
3  Using Arduino / Programming Questions / Re: How to read a register on the 32U4 on: September 23, 2014, 07:32:37 am
Uh, that was fast! Thanks for the answer, I will try it as soon as I get home.
4  Using Arduino / Programming Questions / How to read a register on the 32U4 on: September 23, 2014, 06:26:23 am
Dear all,
I am designing a Leonardo based radiometer with a USB-charged LiPo-battery.
As far as I understood the 16/32U4 datasheet (7766F-AVR-11/10) p. 263 f., there is a register called USBSTA, whose last bit is set if the VBUS-Pin of the MCU sees more than 1.4 V. If I would know how to read the register I could define certain actions to take place only if there is a USB connection (like charging the battery, or data transmission to the host computer) or if there is none (like data aquisition mode).
Unfortunately, my programming skills are too scarce for that, and my finds in google seem to have no effect in the IDE. Here in the forum, "register" normally shows how to do something in I2C or SPI.
It would be very helpful if somebody could give me a hint or link to the right direction. Some knowledge about this would allow for a deeper look into the MCUs guts and surely enhance the overall understanding of it.
Thank you very much, have a good time
5  Products / Arduino Yún / Re: Datalogger example - date dependent filename on: September 05, 2014, 03:35:38 pm
Hey sonnyyu,
awesome, it works! It compiles in IDE 1.5.6.r2 but not in 1.5.7 for whatever reason, but who cares?! Thank you so much!
Have a nice weekend
6  Products / Arduino Yún / Re: Datalogger example - date dependent filename on: September 05, 2014, 01:08:27 pm
Hi wildpalms,
thanks for the suggestion. Last night I wildly tried some stuff, including  the char filename [] thing.
I tried your entire code snippet, but unfortunately I got
Dataloggeryun.ino: In function 'void loop()':
Dataloggeryun.ino:85: error: storage size of 'filename' isn't known
But I think there must be a way, especially because we know the length of the filename quite exactly, do we not?!
7  Products / Arduino Yún / Datalogger example - date dependent filename on: September 05, 2014, 03:10:31 am
Hello all,
I am trying to make Yún do what I want, but I am not a linux person, so it takes time. For a datalogger project I would like to get the files named after the date like "ddmmyy.txt". I tried to tweak the getTimeStamp routine and build a namestring, but the compiler does not like it:
  String namestring;
  namestring += "/mnt/sd/";
  namestring += getDayStamp();
  namestring += ".txt";
  File dataFile =, FILE_APPEND);
gives me
Dataloggeryun.ino: In function 'void loop()':
Dataloggeryun.ino:90: error: no matching function for call to 'FileSystemClass::open(String&, int)'
C:\Users\Sebastian\Documents\Importe ab 0605\arduino-1.5.6-r2\libraries\Bridge\src/FileIO.h:81: note: candidates are: File FileSystemClass::open(const char*, uint8_t)

probably because I do not really understand what the rearranged code does and requires in terms of variables and all (again, I am not a linux person and I already understand that one cannot treat the code that way (obviously)). My getDayStamp seems to be ok; but that is not the point here, I think.
I would be very happy if someone could provide some code to achive a day-stamped filename (and therefore a new file after midnight every day). Thank you very much in advance, have a nice weekend
8  Topics / Science and Measurement / Solved, kinda : Something like an ARDULAB, please! on: August 05, 2014, 08:55:36 am
Hello all,
after not getting very far with my programming knowledge I found a solution, which is just really hard to solder, but should do the trick: the MAX14502. It should be even possible to make a shield with it, but I will clone a Leonardo and marry them together. Or look, what a surprise: They published schematics! Yeah!
9  Products / Arduino Yún / Re: Temperature Web Panel doesn't run for me on: August 05, 2014, 08:03:16 am
I discovered that the contents of the www directory are not uploaded to the SD card unless the sketch is uploaded using WiFi.  It certainly would have been nice to mention this in the documentation of the TemperatureWebPanel example.  
Thank you very much, gorillapilot. This little finding ended two frustrating weeks. Well.... not that it works already, but I get more than 404, finally.
I wrote my fair share of manuals and instructions, so I know it is easy to forget to mention some thing or other, or to assume that something is known. But a bit of information like this has to go asap to the sketch!
I find the documentation very unhelpful. I did a lot with classical arduinos, so I am not a total noob, but with the Yun I get nowhere. And most of the comments and posts seem like the geek-speak I am annoyed about when it comes to... well ... linux. Nevertheless, the Yun has wonderful potential, and maybe some of its fathers remember that
Arduino is an open-source electronics platform based on easy-to-use hardware and software. It's intended for anyone making interactive projects.
So let's keep it up, shall we?! After all, Arduino lives from its community as it does from its founders. Thanks to all for the collaborative effort!

PS: Thank you Federico, the REST switch did the trick. Cool!
10  Using Arduino / Project Guidance / Re: TemperatureWebPanel Example - Arduino not getting client request from server on: August 05, 2014, 07:19:02 am
I have seemingly the same problem. Is there any solution yet?
Thanks, cheers
11  Using Arduino / Interfacing w/ Software on the Computer / Re: Enhanced Serial Monitor - DOWNLOAD available on: May 06, 2014, 03:25:22 am
Hi Allan,
wow, very impressive, congratulations. May I get a copy please?
12  Topics / Science and Measurement / Re: Something like an ARDULAB, please! on: May 04, 2014, 04:13:37 pm
that looks promising in deed. Maybe I can figure out how to access the onboard sd card and write all the files to the sketch folder. Thanks!
13  Topics / Science and Measurement / Something like an ARDULAB, please! on: April 21, 2014, 03:12:24 pm
Hello all,
I am not sure where to put this topic exactly; maybe it is not overly misplaced here:
I am building scientific hardware based on Arduinos for a while. One thing I really would like to have is what the guys at seem to have accomplished: a datalogger MCU with USB-stickish easyness of downloading the data: plug and pull the data to your computer. Awesome! Does anybody have an idea on how this is accomplished? I neither do have the money for the chinese approach (buy one and reverse-engineer the crap out of it), nor do I know any other, simpler board that is alike. Unfortunately, I am not a programmer, so I cannot put something "easy" together in C or so to send a string or whatever of data to the serial monitor or a tailored program. I really mean a simple solution like the board appearing as a USB-stick in the explorer (or whatever it is called on a mac). If there are any hints, I would appreciate it very much.
I think this is something really usefull which seems to be missing in the entire arduino universe (hell, I'd return the esplora and the robot for anything like it). It would come in really handy in scientific experiments and would make some stuff a lot easier (like monitoring environmental conditions with a logger that can be read out and charged via an easy to seal mini-usb-port).
Again, any help is appreciated. Many thanks in advance! Let's keep up the contribution!
14  Using Arduino / Project Guidance / Re: Aruino CASIS project on: April 21, 2014, 02:54:34 pm
That statement seems a little oversimplified. What is "space" exactly? There is a difference between LEO (low Erath orbit) and deep space. The ARDULAB seems to be certified for orbits of 400 km. There were 2560s in various space missions even higher up. So I would not concur without a test (which I'll do in 2016. I'll keep you informed).
For the cameras check with adafruit, they have some stuff which might be helpful. Good luck with your space experiment and keep us posted!
15  International / Deutsch / Re: Servo "murmelt" die ganze Zeit on: April 16, 2014, 03:05:28 pm
Danke für die Tips. Ich habe das mit den 20 ms probiert, aber das ist keine Lösung.
detach() funktioniert. Das Servo hat halt keine Haltkraft mehr, aber die  Stromaufnahme geht gegen Null und es ist endlich still. Die Kraft des Servos ist natürlich auf den Widerstand des Getriebes reduziert, aber das reicht. Da ich langsam über eine for-Schleife den Wert erreiche, ist er auch der nächste Anfangswert, ich lese es nicht aus, und es klappt ohne Sprünge.
Schönen Dank und gute Nacht
Pages: [1] 2 3 ... 5