Show Posts
Pages: 1 2 [3] 4 5
31  Products / Arduino Yún / atmel starts python bridge process on: December 10, 2013, 11:02:56 am
Greetings,

Because my python skills are worse then rusty, I want to do the same by using Java. I installed jamvm and now Im pulling my hair out on how the Atmel side starts that python bridge process when the brudge is started on the Atmel side ...

Tips or suggestions anyone?

Kind regards,

Jos

ps . Im typing this on a darn tablet.sorry for the typos. Stupid tablets ...
32  Using Arduino / Programming Questions / Re: Base prefix notation on: May 04, 2013, 05:15:38 am
Quote
int c3=076; <--- This is troublesome
int c4=098; <--- Ahhhh!!!!!! (actually throws a compiler error!)

I don't know why it always makes me crack up, but I love this comment in the 2nd edition of K&R:
Quote
Everyone's favorite trivial change: 8 and 9 are not octal digits

So pre-ANSI, your 098 might not have thrown an error, but I have no idea what it would do.

Those old compilers (from the mid 70s of the previous century) just considered, say, 099 to be equal to 8*9+9 == 81.

kind regards,

Jos
33  International / Nederlands / Re: Leren programmeren on: April 18, 2013, 01:35:23 am
Als je dat boek wilt  kopen, let dan op dat je de tweede editie koopt; er staat 'ANSI C' op de kaft; de eerste editie komt uit de 70er jaren, nog ver voordat die taal door de standarisatiemolen ging.

vriendelijke groet,

Jos
34  International / Nederlands / Re: Leren programmeren on: April 11, 2013, 04:13:15 am
Het boek waar Rob naar verwijst lijkt heel dun, maar de bladzijden zijn ook heel dun; het is de 'bijbel' voor de C programmeertaal (zeer aan te bevelen). Bjarne Stroustup (de maker van C++) heeft 'n dergelijk boek "The C++ programming language"; er is nu 'n derde editie (of 'n vierde?) en je kunt er iemand mee doodgooien; het is 'n 'brick of a book' en het kost je wel 'n jaartje om 't helemaal door te werken en te begrijpen (<--- waarschuwing). Voor de Arduino kun je heel goed met 'alleen' C terecht ...

vriendelijke groet,

Jos
35  Using Arduino / Programming Questions / Re: Need preprocessor advice on: April 10, 2013, 04:34:24 am
Use the '#ifndef' preprocessor directive instead; it makes your (nested) conditions less convoluted.

kind regards,

Jos
36  Using Arduino / Programming Questions / Re: Boolean memory size on: March 24, 2013, 05:08:55 am
A boolean takes up one byte in C++ (zero or not zero for false/true); you can use bit fields in C/C++ that take up single bits; eight of them (one bit each) take up a single byte again.

kind regards,

Jos
37  International / Nederlands / Re: Beginnen met een Uno of een Mega? on: March 20, 2013, 08:01:02 am
Zelf heb ik 'n Arduino 2560 Mega (en ben dus zwaar bevooroordeeld ;-) maar ik vind de 8KB RAM die er in zit nog niet echt veel; als je kunt kiezen raad ik de 2560 Mega aan: lekker veel digitale pinnen (54), 16 analoge poorten, vier USB in/uItgangen, 6 timers en nog steeds veel te weinig RAM ...

vriendelijke groet,

Jos
38  Using Arduino / Programming Questions / Re: Help with Java GUI. on: March 15, 2013, 07:55:53 am
Read Strings from your 'input' Reader and append( ... ) the String to your JTextArea. Take care that the document doesn't become too large.

kind regards,

Jos
39  Using Arduino / Programming Questions / Re: (char)n vs char(n) on: March 10, 2013, 10:03:07 am
'(char)n' is the old C notation; 'char(n)' is C++s functional cast notation; both do exactly the same thing.

kind regards,

Jos
40  International / Nederlands / Re: Communicatie tussen 2 arduino's (integer) on: February 28, 2013, 07:58:44 am
Die 'kabel' tussen de twee Arduinos, is dat 'n usb kabel? Zo ja, dan is 't eenvoudig: baud rate etc. gelijk zette en babbelen maar ...

vriendelijke groet,

Jos
41  International / Nederlands / Re: Communicatie com poort (Arduino) en java on: February 19, 2013, 09:49:15 am
Zelf gebruik ik al 'n tijd RXTX tesamen met de arduino driver (bjigeleverd bij de IDE); w.b. Java, is 't gewoon 'n USBx port openen, baudrate etc. instellen en babbelen maar ;-) Vanzelfsprekend moet de arduino de binnenkomende bytes begrijpen en de juiste commandos uitvoeren (bijv. sensorwaarden naar de Serial bus schrijven). Hier haal ik de RXTX spullen vandaan: http://guides.machinescience.org/mod/forum/discuss.php?d=263

vriendelijke groet,

Jos
42  Using Arduino / Programming Questions / Re: Trying to learn how to code Sketches on: February 19, 2013, 04:06:13 am
Quote
A sketch also has a main() function,
No, it doesn't.
The IDE adds the main to the sketch that you write.

That's what I wrote in my previous reply ;-)

kind regards,

Jos
43  Using Arduino / Programming Questions / Re: Trying to learn how to code Sketches on: February 19, 2013, 03:29:53 am
Quote
I don't know why they decided to use the term "sketch", because it's a C program.
No, because a C program would have a "main".

A sketch also has a main() function, it is written for us and calls the setup() function once and repeatedly it calls the loop() function. It's the IDE that juggles with our C/C++ files, feeds them to the linker (including that main() function) and voila.

kind regards,

Jos
44  Using Arduino / Programming Questions / Re: is a read/write from/to an uint8_t atomic? on: February 18, 2013, 07:55:57 am
I sincerely disagree with the 'religion' that enabling interrupts in an interrupt handler should be a bad thing, but I redesigned (and re-implemented) my handler: it is interrupt driven by changing (rising or falling) edges (it is a state machine again, same as it was before) and I'm going to try both approaches; my main program loop has nothing else to do while a remote key is pressed (there's one user only) so the processor can be 'away from the job' for 0.1s while it's reading the IR remote, but doing the reading entirely interrupt driven doesn't hurt. b.t.w. nice article; I bookmarked it.

kind regards,

Jos
45  Using Arduino / Programming Questions / Re: is a read/write from/to an uint8_t atomic? on: February 18, 2013, 03:51:33 am
You won't lose a millis() tick in 560uS - the interrupt is queued.

Thanks, I have to remember that; I don't think this queueing of interrupts has a buffer? If yet another interrupt happens, will it overrun the already pending interrupt or is it thrown away? As my decoding handler is now, it takes +- 100ms to complete and (so) +- 100 millis() interrupts have happened (and many micros()).

kind regards,

Jos
Pages: 1 2 [3] 4 5