Show Posts
Pages: 1 ... 34 35 [36] 37 38 ... 67
526  Using Arduino / Programming Questions / Re: eeprom on: December 30, 2012, 08:42:36 pm
Negative values are written the same way as any other values.  It's all just bits, right?

There are code samples here: http://arduino.cc/en/Reference/EEPROM

-br
527  Using Arduino / Interfacing w/ Software on the Computer / Re: Leonardo & Firmata on: December 30, 2012, 07:51:46 pm
If your heart isn't set on Firmata, you could try Bitlash + Bitlash Commander:

https://github.com/billroy/bitlash-commander
https://github.com/billroy/bitlash

-br
528  Using Arduino / Interfacing w/ Software on the Computer / Re: Controlling Arduino with Processing GUI on: December 30, 2012, 06:55:50 pm
Interesting project.  Every office should have one.

The way I would approach this problem is to get the Arduino side working and debugged before you start on the GUI.  

You're going to be using the usb serial port to control it from Processing, so why not design the data transfer format to be human-readable commands so you can control it from the Serial Monitor… then when it's working, processing can send those same commands from the GUI to the Arduino.

There are simpler approaches, but suppose you could send these commands to the Arduino via the Serial Monitor or a Processing program:
Code:
setangle(23)
settension(137)
fire()

There is plenty of information here on the forum how to parse serial input and call your C code to work the motor and solenoid.

Good luck with your project,


-br

Edit: grammatical correction.
529  Using Arduino / Installation & Troubleshooting / Re: Screwed arduino bootloader on: December 30, 2012, 02:40:36 pm
It's unlikely you damaged the bootloader by attempting an upload for the wrong board.  It would help to know what you have tried.  Have you tried restarting the various pieces starting with cycling the USB cable on up to rebooting the PC?

-br
530  Products / Arduino Due / Re: Using GCC directly on: December 30, 2012, 12:39:11 pm
Search for "arduino makefile" and you'll find some threads to get you going.

-br
531  Using Arduino / Project Guidance / Re: Setting the time in a wall clock on: December 30, 2012, 11:30:04 am
Sometimes a piece of flexible plastic tubing, like aquarium tubing, makes a good ad-hoc shaft coupler.  It might help to build up the setting knob with vinyl tape or something similar.

-br
532  Using Arduino / Networking, Protocols, and Devices / Re: Problem with PHP sessions on: December 30, 2012, 08:45:57 am
Aren't session related variables implemented using browser cookies to identify the session?  I've not yet seen an arduino web client that supports cookies.  Of course, all browsers do.

Maybe a cookie or PHP session expert will jump in with some thoughts.

More on cookies: http://en.wikipedia.org/wiki/HTTP_cookie

-br
533  Products / The Arduino Starter Kit / Re: About the position of Resistors in project 1 and 2 on: December 30, 2012, 07:57:00 am
In a case like this it does not make a difference whether the resistor is on the anode or cathode.  It limits the current through the circuit either way.  Think of it as a "degree of freedom".

Once you have more parts in play, or more complex active parts, there are fewer "degrees of freedom".

-br
534  Community / Exhibition / Gallery / Re: Bitlash Commander: Web UI toolkit for Arduino on: December 29, 2012, 07:59:48 pm
Thanks for your note.  Hard to know why npm install failed without seeing the output, but it needs to succeed to install all the modules that Commander needs.

The error when you try to start Commander with "node index.js" is the complaint one usually sees when there is no file by the name "index.js" in the current directory.  You need to be in the same directory as index.js for "npm install" to succeed, too.

The whole issue may be "standing in the wrong directory".  Did you do the "cd bitlash-commander", I wonder?  Worth double checking what directory you're in.  You'll see the LICENSE and README.md file as well as a few others in that directory, too.

Be standing in the bitlash-commander directory where index.js is and try npm install and node index.js again; it might all work.

Let me know how it goes, and thanks for giving Commander a try.

Best,

-br
535  Using Arduino / Project Guidance / Re: Access a 'status' page in the browser? on: December 29, 2012, 07:02:49 pm
Bitlash Commander does something similar to what you're describing.  Might be worth a look: https://github.com/billroy/bitlash-commander

-br
http://bitlash.net
536  Development / Other Software Development / Re: Running programs from external storage on: December 29, 2012, 04:52:51 pm
Thanks, Rob.  Here's a link to the "bitlashsd" example, which will run Bitlash script off the SD card:

https://github.com/billroy/bitlash/blob/master/examples/bitlashsd/bitlashsd.pde

It's in the File->Examples->bitlash menu once you've installed Bitlash.  Do read the doc, there is a minor code change to the Bitlash core to enable file script support.

Good luck with your project,

-br
537  Using Arduino / Programming Questions / Re: Im sure there is a better way to do this... on: December 29, 2012, 03:18:54 pm
There would be less code if you used a for loop for the blinky part: http://arduino.cc/en/Reference/For

-br
538  Using Arduino / Programming Questions / Re: Need to reduce the size of code. Any Tips on: December 29, 2012, 02:45:31 pm
There are repetitive code sequences that could be put into their own functions to save space.  Especially the many places where four arguments have to be passed to draw a circle.

See how much code elimination you can do by condensing common code like that into a few functions that get called from several places.  At least that's where I'd start.

Good luck with your project,

-br

539  Using Arduino / Programming Questions / Re: Data in progmem - not working - why? on: December 28, 2012, 04:13:26 pm
Instead of this construct, which I haven't seen before:
Code:
data = pgm_read_byte(image[x]);
…what happens if you try this:
Code:
data = pgm_read_byte(image + x);

-br
540  Using Arduino / Networking, Protocols, and Devices / Re: serial port data on: December 28, 2012, 03:33:35 pm
The default is 8 bits, no parity, one stop bit.

-br

Edit to correctly say "one" stop bit.
Pages: 1 ... 34 35 [36] 37 38 ... 67