Show Posts
Pages: 1 ... 7 8 [9] 10 11
121  Using Arduino / Displays / Re: 4 digit seven-segment display ! on: January 25, 2013, 11:28:26 am
Unless thats a common anode part, then the MAX7219 is not suitable.

common cathode  smiley-grin
122  Using Arduino / Displays / [Solved]correct output on 1 lcd, wrong on another on: January 25, 2013, 11:18:27 am
hello. im using this display http://www.dfrobot.com/wiki/index.php?title=Arduino_LCD_KeyPad_Shield_(SKU:_DFR0009). i am getting correct output on a scott edwards bpp420 serial lcd, but not on the dfrobot display. example, the first displays the year correctly as 2013, the dfrobot displays 2165. ofcourse the code has been modified to work with each one, and text formats correctly on the dfrobot. original code from 1302 library modified to suit my needs for testing. heres the code for the dfrobot display. thank you for looking and taking a crack at it.

Code:
#include <LiquidCrystal.h>
#include <stdio.h>
#include <string.h>
#include <DS1302.h>

/* Set the appropriate digital I/O pin connections */
uint8_t CE_PIN   = 11;                                                 // also tried pins 2, 11, 12, wrang the pins out to ensure im landing the right ones
uint8_t IO_PIN   = 12;
uint8_t SCLK_PIN = 13;

/* Create buffers */
char buf[50];
char day[10];

/* Create a DS1302 object */
DS1302 rtc(CE_PIN, IO_PIN, SCLK_PIN);
LiquidCrystal lcd(8, 9, 4, 5, 6, 7);

void print_time()
{
  /* Get the current time and date from the chip */
  Time t = rtc.time();

  /* Name the day of the week */
  memset(day, 0, sizeof(day));  /* clear day buffer */
  switch (t.day) {
  case 1:
    strcpy(day, "Sunday");
    break;
  case 2:
    strcpy(day, "Monday");
    break;
  case 3:
    strcpy(day, "Tuesday");
    break;
  case 4:
    strcpy(day, "Wednesday");
    break;
  case 5:
    strcpy(day, "Thursday");
    break;
  case 6:
    strcpy(day, "Friday");
    break;
  case 7:
    strcpy(day, "Saturday");
    break;
  }

  //Format the time and date and insert into the temporary buffer
  snprintf(buf, sizeof(buf), "%s %04d-%02d-%02d %02d:%02d:%02d",
  day,
  t.yr, t.mon, t.date,
  t.hr, t.min, t.sec);
  // snprintf(buf, sizeof(buf),"%02d:%02d",t.hr,t.min);

  /* Print the formatted string to serial so we can see the time */
  lcd.print(t.yr);                                                                        // <--------here is output
  Serial.print(t.yr);                                                                        //        it prints wrong in the serial window also, but not on the other bpp420 using softserial library
}


void setup()
{
  Serial.begin(9600);
  lcd.begin(16,2);
   /* Initialize a new chip by turning off write protection and clearing the
   clock halt flag. These methods needn't always be called. See the DS1302
   datasheet for details. */

  rtc.write_protect(false);
  rtc.halt(false);

  // Make a new time object to set the date and time
  // Tuesday, May 19, 2009 at 21:16:37.          
  // Time t(2013, 1, 24, 18, 55, 00, 5);

  // Set the time and date on the chip
  // rtc.time(t);
}


/* Loop and print the time every second */
void loop()
{
  print_time();
  delay(1000);
  lcd.clear();

}
123  Using Arduino / Displays / Re: 4 digit seven-segment display ! on: January 22, 2013, 11:56:45 pm
i have a display from lumex that looks identical to that, i use it with a max7219. let me know if you resolved your issue or not, i can share the code and send the data sheet, but like floresta said they're probably all the same pinout.
124  Community / Bar Sport / Re: Aaron Swartz sucide on: January 22, 2013, 06:18:58 pm
well you know what, i took my post down, because im not here to argue that, i want to enjoy my arduino, and not associate it with political arguing. i am here to ultimately build the Evilduino™ the most awesome arduino controlled robot anyone has ever seen. i think anyone who kills an innocent person in this country should burn, whether it be christian killer, right winger killer, or leftwinger killer. i have served my country over 10 yrs in 3 different combat zones, and i will continue to protect my neighbors and countrymen as best i could, from deranged gun toting morons. thats all im gonna say about that. the evilduino™ cannot come to fruition without this forum, so im backing down on this one. peace.
125  Community / Bar Sport / Re: People hate resistors for their LEDs on: January 22, 2013, 05:16:56 pm
ya i was joking, that was a leftover from another post about ppl asking ppl on the forum to show them how to do blink 13 lol.
126  Using Arduino / Sensors / Re: Mpx4115 pressure sensor solution on: January 22, 2013, 10:05:07 am
that was my own testing code, thats probably why it didnt make sense. the only line needed is the conversion so i left that and took everything else out to stop confusion. my fault.
127  Using Arduino / Project Guidance / Re: external feed or PC feed ? on: January 22, 2013, 10:01:00 am
i thought lm317 adjustable regulator takes in up to 36vdc. that might free up some space using just that to regulate.
128  Using Arduino / Project Guidance / Re: external feed or PC feed ? on: January 22, 2013, 07:23:02 am
are you using all those regulators to step down the volts incrementally to get to 5v? or each regulator is serving a device/sensor at that regulators voltage?
129  Community / Bar Sport / Re: People hate resistors for their LEDs on: January 22, 2013, 07:17:23 am
Quote
i just keep using the leds till they pop and fizzle

Maybe fair enough on the bench but what about in production?

The BBT episode where Sheldon was on at Penny about her check engine light being on, and he wondered if there was a check the check engine light light. (As he does....)

Imagine the liability claims if peeps' engines blew up because the oil pressure lights had all popped and fizzled themselves to death?

hmmm, maybe not using resistors is why i cant get the pin 13 blink sketch to work??  smiley-confuse and if you work with the engineers you spoke of in another post, the ones who ask everyone else for answers, you can easily lay the blame with them because they're clueless already!!  smiley-eek

lol but im only kidding bout not using resistors


130  Community / Bar Sport / Re: RANT ALERT: All the college / uni project questions on: January 22, 2013, 07:12:04 am
sigh, i kind of agree with this rant

yup, i totally agree with

Quote
My rant goes to senior students with no clue how to go about a problem solving exercise other than asking someone else for the answers.

but your a nicer guy than i am, you would fire them, i would hire assasins.
131  Community / Bar Sport / Re: People hate resistors for their LEDs on: January 22, 2013, 07:02:03 am
just do what i do, dont use resistors, i just keep using the leds till they pop and fizzle. they're so cheap just buy tons of em.  smiley-eek-blue
132  Community / Bar Sport / Re: Measuring the speed of light using cheese. on: January 22, 2013, 06:54:31 am
this wouldnt work because farnsworth said that in 2208 scientists increased the speed of light.
133  Community / Bar Sport / Re: RANT ALERT: All the college / uni project questions on: January 22, 2013, 06:50:20 am
sigh, i kind of agree with this rant, but, why respond to it if it is something that makes you want to go on a rant? people may come here thinking that electronic pros/hobbyists are more than happy to do what they're asking of the forum. i certainly did. in my case, im an olderrrr gentleman, retired, disabled veteran, nothing to do nowhere to go, i chose this (arduino) as a hobby. i been fiddling with stuff like this for years, so in some cases a lil refresher is all it takes for me, especially since the language is new to me. so gosh darn it why wont you tell me how to get an led to blink on pin 13!! besides, has anyone tried the search feature on the playground? maybe mine is the only one thats broke then because more often than not it returns nothing! hey, one good rant deserves another  smiley-grin
134  Community / Bar Sport / SkyNet on: January 22, 2013, 06:41:04 am
skynet started with a single arduino.
135  Community / Bar Sport / Re: Flattr- the next Facebook? on: January 22, 2013, 06:39:41 am
paypal? besides all the folks here worth donating to, how bout all the belittling from some smarter (smarter with arduino) folks to noobs on this site? should we get money from those ppl? lol. i think we should, especially in more cases than not, they only add to the problem we noobs are trying to solve and show the world who they really are. but i generally support an idea like this, unless im missing something though, it seems this wheel has been invented before.
peace  smiley-cool
Pages: 1 ... 7 8 [9] 10 11