Phi-2 shield 20X4 newer version
November 16, 2012 16 Comments
Here are two pictures of the newer version of phi-2 shield 2004. The only real difference is I am shipping female headers with long pins, instead of just female headers with short pins. This makes the kit much easier to assemble and stack. Remember, for those pins where the shield plugs into arduino, the female headers with long legs should be used instead of male headers.
Here is a collection of pictures for your reference?
I bought a PHI-2 20×4 kit from DIPMicro (http://www.dipmicro.com/store/JL-PHI-2-20X4) a few weeks ago and just got some time to start putting it together today.
I’m a little disappointed with the instructions in the documentation. They might be alright for a different board than what I have but for my “Phi- shiekd-2004 v2 03262012” they don’t jive. In spite of the lack of assembly instructions I forged ahead and have assembled most of it but have now run into a few road blocks. It appears that the kit components are for a different version of the PHI-2 20×4.
According to the printing on the board just to the right of the LCD header I need a 220Ohm resistor. The kit didn’t come with one (but I have a spare 150Ω resistor).
Can I use the 150Ω resistor in place of the 220Ω without frying anything?
Below the battery and just to it’s left 2K0Ohm is printed on the board but again the kit didn’t have one.
Do I need a 2kΩ resistor here? And if I do (since I don’t have a 2kΩ) what is the max/min value I could use there?
None of the LCD and main board holes line up. Did I get the wrong LCD in my kit or is this “normal”?
Thx,
TekMason
TekMason,
Sorry about the bad experience you got. Dipmicro is no longer carrying this kit as of the end of last month. They are simply moving away from carrying kits and selling off what they have at hand. Yes, you can use 150 ohm on the LCD, which just makes the LCD back light a tid bit brighter. The 2K ohm resistor is not included because the included real time clock doesn’t need it. The location is just for some other I2C EEPROM or real time clock that specifically requires this pullup resistor. Can you post a picture of your LCD and main board so I can make an evaluation? Thanks.
Thanks for the quick response.
I have some images of my PHI-2 on the Maker Canada Discussion Forums in this thread http://forums.makercanada.com/topic108.html#p182
TekMason
OK, the third image, where a 16 pin female header is on top left, is where the LCD goes. You need to solder male header to the LCD, facing down so they plug into the female header. You want to use the female headers with long legs for arduino shield pins instead of using male pins. This allows you to access these pins on top of the shield.
Hi liudr,
Yep I did have the male header soldered onto the LCD but you can’t see it in my photo.
I figured I should have used the female headers but for a stupid reason didn’t until it was too late. Replacing them will be a bit of rework and since I don’t need access to those pins right now I’ll leave it until after I get the PHI-2 working.
I soldered the 150Ω resistor into the spot where it says 220Ω and tried it out with Phi_2_testing_v3. Nothing.
I tried to see if I could identify the issue but couldn’t figure it out. From my testing it looks like the pb inputs are floating.
All of the troubleshooting steps I could think of are noted in this post http://forums.makercanada.com/topic108.html#p188.
Any suggestions?
Thanks again for your assistance.
TekMason
What about adjusting the potentiometers? The pictures look pretty decent. If you get some solder wick, you can remove the male pins and replace with female pins with long legs. Can you just load blink and adjust contrast until you see two rows of blocks?
Hello, I posted a few questions, but I am just going to post them in this one comment. A week ago I ordered a 2004 Phi-2 shield from inmojo.com
1) My kit did not come with the proper resistors and it is missing an 8 contact DIP Socket for the Ds1307 clock. What resistors do I need for the alarm clock project and can I solder the Ds1307 clock directly into the board because my engineering project is due in a few days so I don’t think I have time to order a socket
2) Can I extend the buttons and LED’s and Piezzo speakers using wires soldered into the board so I can place the buttons and LED’s on a faceplate I 3D printed?
3) Do all the long pin female headers go into every single digital and analog pin in the Aduino UNO I have, or only certain pins are needed?
4) Any other small tips that would be helpful specifically with the Alarm clock project?
Steven,
Sorry about the resistors. For a while I have stopped including the DIP socket in the kit. Nobody has told me they needed to replace a dead DS1307 and on one or two occasions one of the contacts in the socket became lost so I had to send in a replacement socket. The resistors are supposed to be 330 ohms for the LEDs and buzzer. Did I send you 2.2K ohm? That would still be alright for the LEDs but a bit small for the buzzer. For extending buttons, I’ve used 6.5mm square buttons with long actuators I got from ebay. The longest ones are long enough. Otherwise you need separate actuators (plungers) to push the short button caps, like what most buttons have. They usually use acrylic sticks to extend the LEDs to the height of the face plate. Of course you can wire to the board so you can place the LEDs and buzzers against your 3D printed face plate. Yes, all analog and digital pins are brought to the female headers. Some are already in use by the LCD, buttons etc. I have a more updated alarm clock code that I’ve maintained for a few years. It has standard alarm clock features such as time/day of the week/once/weekday etc. I’ve just finished updating the code to run on the latest arduino IDE. I’ll post it here soon.
I went and bought some resistors and finished soldering everything onto the board and soldered the Ds1307 straight onto the board.
The buttons will be in different locations on the 3d printed faceplate so I need to simply attach some wires to the holes in the circuit board for the 6 buttons and the piezzo speaker and LEDs because I am going to have two piezzo speakers and 7 LED’s and the 6 buttons and these will all be on my faceplate. I plan on wiring a few more LED’s to the original LED’s and creating a chain in series with resistors and do same thing with the two Piezzo speakers. That should work I believe so they all just run off the original holes for the original two LED’s and one piezzo speaker?
My project is due next Tuesday, Is there any way you can upload the most recent alarm clock code by the end of this week, so I can begin implementing the software as soon as possible.
Final question! Sorry for all this, I am quite new to everything, this is for my freshman engineering project. I am having a hard time finding exactly what wires I need to attach to the phi-2 shield, I see an orange wire in one of the pictures, and in other pictures I see more wires. What needs to be connected specifically for the Alarm clock?
Thank You!
I uploaded the 3 libraries needed and the alarm clock sample code. No wiring other than wiring the buzzer pin to A2.
https://liudr.wordpress.com/libraries/download/
Thank You for the new code! I want the LED’s to blink and the buzzer to go off when the alarm goes off and to stop blinking and stop buzzing when the button is pressed to turn off the alarm. Where do I add the information for the LED’s and buzzer to turn on and turn off?Because I have dualcolor LED’s I want to use and so I want them to turn red when the alarm is going off and turn green when the confirm button is pressed.
Also, do I need to wire the LED’s to a digital pin and how do I do that or is all this already in your code?
This function contains the action when the alarm is triggered:
void alarm_clock::alarm()
The wait_on_escape() will wait for button presses. Give it a try. Don’t forget to give me some credit if you turn this in as school project. I’m a professor myself. Wouldn’t want a copy+paste project from any student but if he states that he worked on a certain portion of the project while the rest is from others, that is OK by me.
Oh of course, the design is all built in solidworks and 3d printed but the coding is open source from you and there will be credit given no worries. Just need to change a few thigns so the LED’s blink when i want them too. Thank You!
Also what is the difference between Alarm_clock and Phi_2_project_alarm_clock_v1_6_?? Which one do I upload to the Arduino and which one do I edit for the LED/buzzers? I’ve never worked with multiple codes open at once.
Alarm_clock is just a part of the project, one code file, among a few. Phi_2_project_alarm_clock_v1_6_0 is the main code file. If you are able to open the project in Arduino IDE and compile it, it will compile and upload everything. Just keep all the files in a Phi_2_project_alarm_clock_v1_6_0 folder. Can you post a link or two to your final project or pictures?
Okay, I understand now. I will submit some pictures of the final project! Still having trouble finding where to place the code for my LEDs to turn on when the alarm goes off? Do I have to set OUTPUT values for the LEDs somewhere in the code?
There is already code for the buzzer to turn on when the alarm turns on, but you did not place code for the LEDs? is that right? Where exactly would I place the code for the LED’s? Could you walk me through this code in layman’s terms?
int temp1;
for (int i=0;i<total_beeps;i++)
{
tone(buzzer,770);
temp1=wait_on_escape(75);
if ((temp1==5)||(temp1==6))
{
noTone(buzzer);
alarm_is_on=false; // Turn off alarm
return;
}
noTone(buzzer);
temp1=wait_on_escape(75);
if ((temp1==5)||(temp1==6))
{
noTone(buzzer);
alarm_is_on=false; // Turn off alarm
return;
}
}
temp1=wait_on_escape(150);
if ((temp1==5)||(temp1==6))
{
noTone(buzzer);
alarm_is_on=false; // Turn off alarm
return;
}
}
This should be my FINAL question, I promise. I have been reading soo much, hours everyday. Definitely way above the basic coding in Arduino I knew. Thank You for answering all my questions and being very quick to respond!
That IS the function where you add your LED code. Yes, declare LED pins as output in setup(). Did you run the example code in Arduino IDE called Blink? That’s your square one.