Show Posts
Pages: 1 ... 41 42 [43] 44 45 ... 80
631  Using Arduino / LEDs and Multiplexing / Re: Dual 7 segment counters with triggers for adding & subtracting from 00 to 99 on: February 14, 2013, 01:00:01 am
At the site in my signature block below there is code for a timer display that allows you to preset the value and then it counts down. You  may be able to use some of the code for our own purposes.
632  Using Arduino / Displays / Re: How to print chinese char on LCD 16x2 Display? on: February 10, 2013, 07:09:51 am
The character set I stored in the LCD ROM. You need to check what it contains either by looking up the number for the rom or by printing all the chars from 1 to 255. In my rom the top 127 chars contain Japanese chars.

Personally I think it is hard to see how all the Chinese chars would be available.

If you only need 8 or less you may be able to use the user defined characters.
633  Using Arduino / Sensors / Re: TCS230 clarified. Hardware Modified, code strengthened, hair lost. on: February 08, 2013, 07:46:29 pm
Thanks for this post, certainly saved me the pain of the GND/OE connection.
634  Using Arduino / Programming Questions / Re: Basic Coding question on variables on: February 08, 2013, 03:16:37 pm
For readability the second is better as you can group all these constants together at the top of the sketch.  Even better is to call them const if they will never change.

Because the led variable has a global scope it will persist and you can change it from anywhere. However, in your first case it does not have a value until setup is called. In the second case the compiler initialises the memory location so it has that value when the program starts running. In the arduino this makes no difference because setup is called first. On other systems it might.
635  Using Arduino / Programming Questions / Re: Checksum error on: February 08, 2013, 06:13:46 am
... And there is no way that a byte quantity can have 3 digits.

Are you sure that you are printing the value in hex all the time? Can't see mdb_dump anywhere.

Helpful debug would also be to print the value it should be when the test fails. That may give you a clue.

Checksums may not include every character received, for example the start of a packet, so are you sure you are using the right data?
636  Using Arduino / Programming Questions / Re: Checksum error on: February 08, 2013, 04:15:10 am
An array of size 30 has indices 0 to 29, so you probably mean 29 if you intend the last character.
637  Using Arduino / Programming Questions / Re: Can't unpload to Mini Pro on: February 08, 2013, 03:05:19 am
The basic issue is that there is no automatic reset of the Mini Pro when the serial line becomes active.

Here is the process that I use:
1. Start the compile/download cycle
2. At some point the 'Rx' LED on the MiniPro will flash.
3. Press the reset button when this happens.
4. The bootloader will take over on reset and allow the download to be executed.

It can be a bit tricky, but like most of these things the timing will comm with practice smiley

An alternative is to modify the Pro Mini woith a capacitor (from memory) that reset the serial line. You can search for this using google.
 
638  Using Arduino / Sensors / Re: Temperature sensor LM335 on: February 07, 2013, 05:58:38 am
Follow the link at the bottom of my post.
Look for the library int the downloads section.
Read the code to understand or just use it.
639  Using Arduino / Displays / Re: counter with 7 segment LED serial display on: February 07, 2013, 05:36:07 am
Yes. You need to connect the power pins at least - how do you expect it to work otherwise.

The other pins depend on the device. If you look on the IC you will see a number (like 74HC595 or something) that will tell you the device type. If you then google that with arduino you will probably find example code.

640  Using Arduino / Sensors / Re: Temperature sensor LM335 on: February 07, 2013, 05:30:18 am
I have a library with example code at the link in my signature block.  Generally you would need to read the datasheet for the sensor as all the info is there.
641  Using Arduino / Project Guidance / Re: MIDI Controller Help for Senior Project on: February 07, 2013, 05:27:16 am
No idea on this one.  Why not just set one up and see how it goes?
642  Using Arduino / Programming Questions / Re: Real Time Clock module to display time and date on LCD on: February 06, 2013, 02:14:19 pm
Have you looked at my library as suggested above for sample code and a working example?
643  Using Arduino / Programming Questions / Re: Compare Dates - Times on: February 06, 2013, 05:12:58 am
%02d puts the leading zero in for you.  What you need to do is make sure the time is in 24 hour format so that 1 am is 01 and 1 pm is 13. The string will always be the same length.
644  Using Arduino / Programming Questions / Re: Compare Dates - Times on: February 06, 2013, 04:31:57 am
If in your case equal is correct then implement it the way you think it should be.
645  Using Arduino / Programming Questions / Re: Compare Dates - Times on: February 06, 2013, 03:56:08 am
Strcmp() returns different values depending on whether the strings are equal, greater than or less than.
Pages: 1 ... 41 42 [43] 44 45 ... 80