I looked through your the code in "Auto Package Alert - Receiver v.3.2.spin." Usually the numbering for days or the week (dow) starts with Sunday. The way your code is now, system would be off on Friday and Saturday. I don't know if the DS1302 lets you set the days of the week independently of the date (I think it might), but even if you can change the chips numbering of the days, I think it would be better to follow convention and keep Sunday as day 1.
I didn't see any way of setting the clock. A lot of real time clock aren't very accurate and will need to be adjusted occationally.
Another feature would be to keep track of daylight savings time and automaticly adjust the time.
You could also make the times the monitor is on or off user settable and save the settings in EEPROM.
Is there a way to override the on/off state. What if they are expecting a Saturday delivery? Can the turn it on?
There are zillion little things that make a product polished. It can be a pain to think of them all and even a bigger pain to program them but the little things can be so helpful to the end user.
The transistor is still bothering me. The transistor/relay pin is always in an output state. This will allow current to flow into the Prop when the pin is low and will source current when high. You need to make sure that neither of these currents are too high. The Prop has a 40 mA limit, but it wouldn't be good to have that much current hours at a time. I think a constant 10mA, or lower would be a better target.
I still think a latching relay would be a better choice. (My offer still stands, I'll send you one if you want.)
@Duane: I have the clock set to where the week starts with Monday, but I guess I can go to conventional methods if the need be. The day of the week IS independent of the date, however, if I am not mistaken the DS1302 datasheet indicates that it automatically adjusts to Daylight Savings until year 2100.
@All: I'll replace the transistor with an NPN once I get a new one.
Where is you general location? I'd think there has got to be a forum member near you who'd part with a few NPN's. If they're close the mail should just take a couple days.
If the PNP works, I don't see a problem. Just make sure the current to or from the Prop is within specs.
I just checked the transistor. It is a PNP and I was mistaken about the exact part number, it is a 2N4403. Still, the emitter IS to ground, the collector IS to the coil, and the circuit DOES work.
I don't know how, but it does.
His circuit works because you are connecting correctly, but your diagram is wrong, your diagram does not work in practice.
It is so basic.
To say that Q1 operates is like saying that D1 conducts electricity normally.
Transistors conduct electricity only in one direction, like diodes, can even be used as diode rectifiers.
I have a picture for you. I used a copy of D1 to make the example clearer.
Note: The diode goes from emitter to base, but the idea is also valid to represent the emitter and collector (PNP transistor).
On the projects you do, test them every which way you possibly can. Have someone else think of and try every situation and everything that could go wrong. I would even write some diagnostic code that shows an error light when a switch is stuck, power was lost, etc.
I work daily with coders and in more than half the cases their deliverable is actually a proof-of-concept and simple for me to cause fatal errors with a business process.
Writing the switch / xbee / display will be trivial for you. I suggest you make it your goal that Ken can not find a way to break your product (other than with a hammer)
I have found in my life that you can make money in the spaces between two disciplines. Coders are frequently weak in social skills; they would be petrified lecturing. Teachers are frequently weak in technical skills. Technical teachers are in demand because they are comfortable in both worlds.
Here is where this applies to you. There may be a gap between coders/builders and computer network admins. I think there are businesses that would like some type of monitoring to show up on a website. Their interest could be temperature, humidity, fluid level, light, etc. The set of gas sensors from Parallaxx would make a nice suite. You can probably get a lot of sensor project ideas from these fora.
You are probably a fine coder/builder. Now get up to speed on the network admin side with the PINK or Hydra EtherX and then test a project in as many networks as you can to figure out the TCP/IP situations.
I think that the applications are so broad that you might get hits from Craigs List
Maybe Ken would find it more efficient to have the parcel status available to everyone on the Parallax LAN rather than just the person sitting next to the receiver.
OK, I'll be gone all of next week, so this week I am going to try to crunch in as much extra features to the device that I can, and then I MIGHT be able to ship it out before I leave.
Of course, maybe I'll just keep it a little longer to make SURE that there are no bugs in the system.
Comments
I looked through your the code in "Auto Package Alert - Receiver v.3.2.spin." Usually the numbering for days or the week (dow) starts with Sunday. The way your code is now, system would be off on Friday and Saturday. I don't know if the DS1302 lets you set the days of the week independently of the date (I think it might), but even if you can change the chips numbering of the days, I think it would be better to follow convention and keep Sunday as day 1.
I didn't see any way of setting the clock. A lot of real time clock aren't very accurate and will need to be adjusted occationally.
Another feature would be to keep track of daylight savings time and automaticly adjust the time.
You could also make the times the monitor is on or off user settable and save the settings in EEPROM.
Is there a way to override the on/off state. What if they are expecting a Saturday delivery? Can the turn it on?
There are zillion little things that make a product polished. It can be a pain to think of them all and even a bigger pain to program them but the little things can be so helpful to the end user.
The transistor is still bothering me. The transistor/relay pin is always in an output state. This will allow current to flow into the Prop when the pin is low and will source current when high. You need to make sure that neither of these currents are too high. The Prop has a 40 mA limit, but it wouldn't be good to have that much current hours at a time. I think a constant 10mA, or lower would be a better target.
I still think a latching relay would be a better choice. (My offer still stands, I'll send you one if you want.)
Duane
@All: I'll replace the transistor with an NPN once I get a new one.
If the PNP works, I don't see a problem. Just make sure the current to or from the Prop is within specs.
Duane
His circuit works because you are connecting correctly, but your diagram is wrong, your diagram does not work in practice.
It is so basic.
To say that Q1 operates is like saying that D1 conducts electricity normally.
Transistors conduct electricity only in one direction, like diodes, can even be used as diode rectifiers.
I have a picture for you. I used a copy of D1 to make the example clearer.
Note: The diode goes from emitter to base, but the idea is also valid to represent the emitter and collector (PNP transistor).
I work daily with coders and in more than half the cases their deliverable is actually a proof-of-concept and simple for me to cause fatal errors with a business process.
Writing the switch / xbee / display will be trivial for you. I suggest you make it your goal that Ken can not find a way to break your product (other than with a hammer)
Here is where this applies to you. There may be a gap between coders/builders and computer network admins. I think there are businesses that would like some type of monitoring to show up on a website. Their interest could be temperature, humidity, fluid level, light, etc. The set of gas sensors from Parallaxx would make a nice suite. You can probably get a lot of sensor project ideas from these fora.
You are probably a fine coder/builder. Now get up to speed on the network admin side with the PINK or Hydra EtherX and then test a project in as many networks as you can to figure out the TCP/IP situations.
I think that the applications are so broad that you might get hits from Craigs List
Maybe Ken would find it more efficient to have the parcel status available to everyone on the Parallax LAN rather than just the person sitting next to the receiver.
Of course, maybe I'll just keep it a little longer to make SURE that there are no bugs in the system.