ADA1141 data logger shield with DFRobot RGB screen

Adafruit Ethernet, Motor, Proto, Wave, Datalogger, GPS Shields - etc!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
User avatar
adafruit_support_bill
 
Posts: 88172
Joined: Sat Feb 07, 2009 10:11 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by adafruit_support_bill »

Some redundant code there. And several places where it could hang. What do you see in the Serial Monitor when you run that code?

User avatar
NATTI_01
 
Posts: 16
Joined: Thu Mar 07, 2024 4:32 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by NATTI_01 »

Hi Bill
Agree lot's of redundant stuff but it does verify the RTC & SD existance and prints to the I2C screen exactly what I wanted
The serial monitor output shown in attached screen shot, yes, not all printing happened to the monitor BUT exactly what I wanted to the I2C did
Attachments
Serial monitor SD & RTC.pdf
(33.8 KiB) Downloaded 1 time

User avatar
adafruit_support_bill
 
Posts: 88172
Joined: Sat Feb 07, 2009 10:11 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by adafruit_support_bill »

Looks like the SPI and I2C buses are both operating correctly.

This line of code can be deleted. Pin 10 is the default CS pin for the Arduino SPI bus. Older versions of the Arduino system didn't behave well if you tried to re-assign it.

Code: Select all

  pinMode(10,OUTPUT); //Instruction from Adafruit that we must do this when pin 10 is reassigned as above
Your DF-Robot board is using the default SPI CS pin for backlight control. And this line is turning off the backlight on your display. You probably want to delete that as well.

Code: Select all

digitalWrite(10,LOW); //usw with DFR0009

User avatar
NATTI_01
 
Posts: 16
Joined: Thu Mar 07, 2024 4:32 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by NATTI_01 »

Hi Bill
Pin 10 is isolated from the ADA1141 shield so that it could carry thru to the DFR0009 screen to turn the backlight ON/OFF, that works fine. Pin 10 on the ADA1141 is connected to CS (SD Card Start) UNTIL I cut the link and re-assigned CS to pin 2. We know this works because the SD card is functional.
We have done everything according to your data sheets, made pinMode(10,OUTPUT); remember this is a UNO R3...
There is something else about the ADA1141 that is interfering with the lcd.print and without a complete schematic to table all the outputs from the UNO thru the ADA1141 onto the inputs of the DFR0009 screen like something pulling any of pins 4 thru 9 down or sending them high, mate I'm at my wits end...
Never thought that integration of such a useful shield could turn out this badly

User avatar
adafruit_support_bill
 
Posts: 88172
Joined: Sat Feb 07, 2009 10:11 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by adafruit_support_bill »

without a complete schematic to table all the outputs from the UNO thru the ADA1141
The schematic and complete CAD files are all right there in the documentation: https://learn.adafruit.com/adafruit-dat ... /downloads

As you can see, the shield is compliant with the R3 standard. It uses just the i2c and SPI bus, plus the Arduino default CS pin 10 which is re-mappable. We have sold many thousands of these boards. And since it uses all bus-based interfaces, it plays well with other boards that adhere to the standards.

As you can also see, it includes optional jumpers to configure for pre-R3 Atmega 128 & 328 Arduinos that do not have dedicated pins for SPI and i2c. Your R3 UNO still uses the Atmega328, so although it supports the R3 pinout, the old i2c and SPI pins are not available for other purposes.

Looking at the DF0009 schematic, it looks like a rather old design and is not compliant with the R3 standard Arduino pinout. Although it does not appear to need any of the pins it is missing.

User avatar
NATTI_01
 
Posts: 16
Joined: Thu Mar 07, 2024 4:32 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by NATTI_01 »

Hi Bill
Shortly after I wrote to you last night I thought I would start from scratch with a spare ADA1141 I had, soldered on the headers BUT this time left off the 2X3 ICSP headers, jumped 11,12 and 13 and I now have the RTC, SD and the DFR0009 combo working! I've left pin 10 alone for now but will work on the back light control on the DFR0009 later.
Bill I would like to thank you for persisting with me on this, I am learning (pretty obvious heh!) but have learnt so much in the last week or so interacting with you, compared with nothing from other forums, I am so grateful.
Now to get in and write some more code to get the data logged to the SD card from my analog current sensor... will keep you posted
Regards
Darryl

User avatar
adafruit_support_bill
 
Posts: 88172
Joined: Sat Feb 07, 2009 10:11 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by adafruit_support_bill »

Good to hear you have got it working. Thanks for the follow-up.

User avatar
NATTI_01
 
Posts: 16
Joined: Thu Mar 07, 2024 4:32 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by NATTI_01 »

Hi Bill
Thought an update is in order... the DFR0009 remains a nightmare. I thought we had it until I tried to print to the second row and it went nuts! The RTC lost it's time, the sketch went into an uncontrollable loop and it didn't print.
Where I am at now is the UNO R3, the ADA1141 shield without the 2X3 headers, pin 10 untouched, an I/O expansion shield with I2C that I can plug the LCD1602RGB I2C display into and it works a treat! Found the SD, the RTC is tickin' away and the screen prints fine. All I'm missing is the push buttons which was the whole point of using the DFR0009 LCD...
I've looked very closely at your 714 but you can't plug anything into anything...
I'll come back to the DFR0009 some other time, there must be something we haven't recognized which is playing havack, just can't put my finger on it at the moment

User avatar
adafruit_support_bill
 
Posts: 88172
Joined: Sat Feb 07, 2009 10:11 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by adafruit_support_bill »

the DFR0009 remains a nightmare. I thought we had it until I tried to print to the second row and it went nuts!
HD44780 based LCD character displays are very old technology and can be temperamental. But that usually just results in either scrambled displays or no output at all. Not sure what would cause it to crash your code, but I have not examined the DFRobot display library.
I've looked very closely at your 714 but you can't plug anything into anything...
You do have access to all of the header pins via the breakout holes on the logger shield. If you want them available externally, there is also the screwshield: https://www.adafruit.com/product/196

User avatar
NATTI_01
 
Posts: 16
Joined: Thu Mar 07, 2024 4:32 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by NATTI_01 »

Hi Bill
Like a dog with a bone, don't give up... mate happy to tell you I think I have the problems licked.
I've got the DFR0009 LCD off the stack and using jumpers to keep pin 10 isolated, the ADA1141 has no 2X3 ICSP header, I have soldered 11,12,&13 and kept pin 10 for Card Start, used example sketch components of CardInfo & pcf8523 with LiquidCrystal and temporarily jumped pin 10 of the LCD to D2, pinMode(2,OUTPUT); and have identified the SD and the clock is keeping time and the final objective being to turn the backlight ON & OFF by writing to pin 2 achieved...
What you might find interesting is what sits on pin 10 on the LCD side when it is just in air, 3.5V ! I found an article that identified pin 10's function actually switches a transistor... when you designate the pinMode(2,OUTPUT); in void setup, actually drops the pin to LOW and the backlight goes off so before you can print to the LCD you need to digitalWrite(2,HIGH); to start it up again...
Man have I learnt a lot in the last couple of weeks!
Anyway, tomorrow I'm going to remove pin 10 from the DFR0009 and jump it across to pin 2 so I should be able to just drop it back on top of the ADA1141 and start having some fun with the buttons...
Again, thankyou so much for your patients and I can assure you that Adafruit will be my first port of call for product in the future... might even get a 714 now and have a play with that
Regards
Darryl

User avatar
adafruit_support_bill
 
Posts: 88172
Joined: Sat Feb 07, 2009 10:11 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by adafruit_support_bill »

What you might find interesting is what sits on pin 10 on the LCD side when it is just in air, 3.5V !
Not surprising. The schematic shows a 4.7K pullup resistor (R7) on the base of the transistor connected to D10. That assures that the transistor is ON by default. You need to actively pull D10 LOW to turn off the backlight.
https://image.dfrobot.com/image/data/DF ... %20SCH.pdf

User avatar
NATTI_01
 
Posts: 16
Joined: Thu Mar 07, 2024 4:32 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by NATTI_01 »

Hi Bill
Would have been nice to have known this weeks ago heh! That voltage sitting on pin 10 all the time must have been what was causing all my nightmares...
I've routed header pin 10 on the DFR0009 side (bent it away so it can't plug in to the ADA1141) and jumped it around to pin 2... not using ICSP and have soldered 11,12 & 13, backlight control via pin 2 , all works a treat.
I now have the data logger package I originally set out to build.
I will revisit the ICSP shield now that we know about that 3.5V on pin 10 of the LCD and hopefully make that work as well.
I'll get your I2C LCD and the screw terminal sheild to build up another datalogger soon.
Again thanks for your help

User avatar
NATTI_01
 
Posts: 16
Joined: Thu Mar 07, 2024 4:32 am

Re: ADA1141 data logger shield with DFRobot RGB screen

Post by NATTI_01 »

Hi Bill
Change of topic sorry, I struggle navigating the forum for info on the TFT screen that I just smashed on my Arduino MKRIoT Carrier...
It is 1.3" TFT 240 x 240 part number LH133T-IF05 which comes up as an Adafruit product...
Your shop shows Product ID 4520 similar specs, is it a replacement for the one I just busted?
Thanks
Darryl

Post Reply
Please be positive and constructive with your questions and comments.

Return to “Arduino Shields from Adafruit”