Show Posts
Pages: [1] 2 3 4
1  Using Arduino / Programming Questions / Re: Digital Temperature Sensor - DS18B20. Code does not work on: December 29, 2013, 06:55:26 pm
redone all connections do DS1820 and replaced resistor 2K2 instead of 4K7.
everything is working now.
Probably problem with resistor.
Thank you.
2  Using Arduino / Programming Questions / Re: Digital Temperature Sensor - DS18B20. Code does not work on: December 29, 2013, 10:17:27 am
this sketch also is not working.
which pin are you using?
3  Using Arduino / Programming Questions / Re: Digital Temperature Sensor - DS18B20. Code does not work on: December 29, 2013, 01:44:16 am
3.9 kOhm to +5V
4  Using Arduino / Programming Questions / Re: Digital Temperature Sensor - DS18B20. Code does not work on: December 28, 2013, 10:51:46 pm
Also cannot find devices using this code:
Code:
// This sketch looks for 1-wire devices and
// prints their addresses (serial number) to
// the UART, in a format that is useful in Arduino sketches
// Tutorial:
// http://www.hacktronics.com/Tutorials/arduino-1-wire-address-finder.html

#include <OneWire.h>

OneWire  ds(A3);  // Connect your 1-wire device to pin 3

void setup(void) {
  Serial.begin(9600);
  discoverOneWireDevices();
}

void discoverOneWireDevices(void) {
  byte i;
  byte present = 0;
  byte data[12];
  byte addr[8];
  
  Serial.print("Looking for 1-Wire devices...\n\r");
  while(ds.search(addr)) {
    Serial.print("\n\rFound \'1-Wire\' device with address:\n\r");
    for( i = 0; i < 8; i++) {
      Serial.print("0x");
      if (addr[i] < 16) {
        Serial.print('0');
      }
      Serial.print(addr[i], HEX);
      if (i < 7) {
        Serial.print(", ");
      }
    }
    if ( OneWire::crc8( addr, 7) != addr[7]) {
        Serial.print("CRC is not valid!\n");
        return;
    }
  }
  Serial.print("\n\r\n\rThat's it.\r\n");
  ds.reset_search();
  return;
}

void loop(void) {
  // nothing to see here
}

Moderator edit: [code] [/code] tags added.
5  Using Arduino / Programming Questions / Digital Temperature Sensor - DS18B20. Code does not work on: December 28, 2013, 10:07:16 pm
I'm trying to use  Digital Temperature Sensor - DS18B20 on Mega 2560.
Code from here: http://www.hobbytronics.co.uk/ds18b20-arduino
The only change is:
    ONE_WIRE_BUS = A3:
Code:
#include <OneWire.h>
#include <DallasTemperature.h>
 
// Data wire is plugged into pin 2 on the Arduino
#define ONE_WIRE_BUS A3
 
// Setup a oneWire instance to communicate with any OneWire devices
// (not just Maxim/Dallas temperature ICs)
OneWire oneWire(ONE_WIRE_BUS);
 
// Pass our oneWire reference to Dallas Temperature.
DallasTemperature sensors(&oneWire);
 
void setup(void)
{
  // start serial port
  Serial.begin(9600);
  Serial.println("Dallas Temperature IC Control Library Demo");

  // Start up the library
  sensors.begin();
}
 
 
void loop(void)
{
  // call sensors.requestTemperatures() to issue a global temperature
  // request to all devices on the bus
  Serial.print(" Requesting temperatures...");
  sensors.requestTemperatures(); // Send the command to get temperatures
  Serial.println("DONE");

  Serial.print("Temperature for Device 1 is: ");
  Serial.print(sensors.getTempCByIndex(0)); // Why "byIndex"?
    // You can have more than one IC on the same bus.
    // 0 refers to the first IC on the wire
 
}

this is the result:
Quote
Temperature for Device 1 is: -127.00
what I'm doing wrong?


Moderator edit: [code] [/code] tags added.
6  Products / Arduino Due / Re: Windows 7 pro 64bit driver for DUE ??? on: June 25, 2013, 08:17:55 am
Thank you,
different USB cable fixed the problem.
Looks like reliability of wires worse then quality of device smiley-sad
7  Products / Arduino Due / Re: Windows 7 pro 64bit driver for DUE ??? on: June 21, 2013, 07:49:33 pm
USB/UNKNOWN
8  Products / Arduino Due / Re: Windows 7 pro 64bit driver for DUE ??? on: June 20, 2013, 05:21:58 am
this pictures are the same on AMD and Intel
9  Products / Arduino Due / Re: Windows 7 pro 64bit driver for DUE ??? on: June 20, 2013, 04:59:24 am

10  Products / Arduino Due / Windows 7 pro 64bit driver for DUE ??? on: June 19, 2013, 10:32:59 pm
Hi I'm trying to install DUE from this guide:
http://arduino.cc/en/Guide/ArduinoDue
after this step:
"Navigate to the folder with the Arduino IDE you downloaded and unzipped earlier. Locate and select the “Drivers” folder in the main Arduino folder (not the “FTDI USB Drivers” sub-directory). Press “OK” and “Next” to proceed. "
Windows just saying the best driver already installed and does not give any other option.
Anybody know how to install the driver?
11  Using Arduino / Programming Questions / Re: Arduino pin mappinig on: May 21, 2013, 06:22:00 pm
thank you, that is working:
Code:
  digitalWrite (A1,HIGH);
  digitalWrite (A2,HIGH);
  digitalWrite (A3,HIGH);
  digitalWrite (A4,HIGH);
what type these variable should be
12  Using Arduino / Programming Questions / Arduino pin mappinig on: May 21, 2013, 05:53:36 pm
from this page: http://arduino.cc/en/Main/arduinoBoardMega2560
I'm trying to use A0-A4 pins:
Code:
  pinMode (0, OUTPUT);
  pinMode (1, OUTPUT);
  pinMode (2, OUTPUT);
  pinMode (3, OUTPUT);
  pinMode (4, OUTPUT);

Code:
  digitalWrite (1,HIGH);
  digitalWrite (2,HIGH);
  digitalWrite (3,HIGH);
  digitalWrite (4,HIGH);
then after 1 minute:
Code:
digitalWrite (1,LOW);
 digitalWrite (2,LOW);
 digitalWrite (3,LOW);
 digitalWrite (4,LOW);

The problem: on these pins always LOW level
what I'm doing wrong?
13  Using Arduino / Networking, Protocols, and Devices / Re: Question regarding RTC libraries on: March 30, 2013, 08:37:34 pm
with TFT and 4.7k Ohm resistors?
14  Using Arduino / Networking, Protocols, and Devices / Re: Question regarding RTC libraries on: March 30, 2013, 08:19:28 pm
does it work now?
15  Using Arduino / Programming Questions / Re: Mega2560 + 3.2" TFT + RTC. RTC problem on: March 30, 2013, 08:15:58 pm
tried this library http://www.henningkarlsen.com/electronics:
Code:
// DS1307_Serial_Easy (C)2010 Henning Karlsen
// web: http://www.henningkarlsen.com/electronics
//
// A quick demo of how to use my DS1307-library to
// quickly send time and date information over a serial link
//
// I assume you know how to connect the DS1307.
// DS1307:  SDA pin   -> Arduino Digital 4
//          SCL pin   -> Arduino Digital 5

#include <DS1307.h>

// Init the DS1307
DS1307 rtc(20, 21);

void setup()
{
  // Set the clock to run-mode
  rtc.halt(false);
 
  // Setup Serial connection
  Serial.begin(9600);

  // The following lines can be commented out to use the values already stored in the DS1307
  rtc.setDOW(SUNDAY);        // Set Day-of-Week to SUNDAY
  rtc.setTime(12, 0, 0);     // Set the time to 12:00:00 (24hr format)
  rtc.setDate(3, 10, 2010);   // Set the date to October 3th, 2010
}

void loop()
{
  // Send Day-of-Week
  Serial.print(rtc.getDOWStr());
  Serial.print(" ");
 
  // Send date
  Serial.print(rtc.getDateStr());
  Serial.print(" -- ");

  // Send time
  Serial.println(rtc.getTimeStr());
 
  // Wait one second before repeating :)
  delay (1000);
}
without TFT on serial it is working fine
as soon as TFT inserted (without any other change) - it does not work
Pages: [1] 2 3 4