Wake My Hardware Up Before You Go-go
Posted: Sat Jul 30, 2011 9:52 am
Following on from the huge smash hit Wake Me Up Before You Go-go everyone's favourite band has released a new track "Wake My Hardware Up Before You Go-go". In this thread of words we learn that in order to get truly high, you have to go way down low!
Both IRQ and XIRQ are level sensitive, though IRQ can be configured to be edge sensitive. In the event that we use XIRQ without the interrupt enabled which I suspect we will, then we need an appropriate voltage level. It would be nice from a code perspective if the signal was consistent, ie, wobbly low voltages won't trigger it and untrigger it continuously (which we could miss with polling).
If the key signal is low voltage (under some threshold that we choose) then the CPU pin should be 5v. When the key signal goes high ("12" volts) then we need to take that pin low to zero volts and leave it there until the key signal goes low again.
Given that we have other mechanism for knowing that it's time to to down, this pin should probably activate with a schmidtt trigger or similar at something like 4v makes cpu go low and 1v makes it go high again. However, thinking about it again, if we do that and for any reason the voltage hangs between our two thresholds, the cpu will never wake up again, or depending on the software perhaps never go to sleep again also.
For the purposes of making sure the power signal is somewhat smooth and consistent we should have two things:
1) a capacitor across the input to smooth things out (perhaps one 10uF tant and one 0.1uF ceramic)
2) a resistor to drain the cap in short order that won't get too hot with continuous 15v applied and won't burn out with continuous 25V applied.
The cap without the resistor would be a terrible idea in case there was only one thing supplied from the relay that triggers this pin (quite likely). The resistor without the cap could result in random voltage swings.
This input pin will feed the BRV divider too, so having a bit of extra filtering on the outside (using the supply wire as a low resistance series resistance for a high cut off RC filter) is a good thing.
If we don't use something like a schmidtt trigger and just use a normal logic gate to invert the signal, then our switch point will depend upon the internal switch point of that device (fed with a zener and rail diodes to cap it) which could vary part to part.
I think I'd prefer the on/off threshold to be around 5v so that random leakage is less likely to appear "on". Whatever happens we don't want the situation where the thing goes to sleep and never wakes up because it went to sleep while the signal was high enough to force the cpu pin low and no transition occurs. Although, at that point it should only be a key on/off cycle away from waking it up, AND, it would only be caused by dodgy wiring anyway. Still, I don't like the idea of not having control of the destiny of the device so perhaps the schmidtt idea is a bad one.
Thoughts?
Fred.
Both IRQ and XIRQ are level sensitive, though IRQ can be configured to be edge sensitive. In the event that we use XIRQ without the interrupt enabled which I suspect we will, then we need an appropriate voltage level. It would be nice from a code perspective if the signal was consistent, ie, wobbly low voltages won't trigger it and untrigger it continuously (which we could miss with polling).
If the key signal is low voltage (under some threshold that we choose) then the CPU pin should be 5v. When the key signal goes high ("12" volts) then we need to take that pin low to zero volts and leave it there until the key signal goes low again.
Given that we have other mechanism for knowing that it's time to to down, this pin should probably activate with a schmidtt trigger or similar at something like 4v makes cpu go low and 1v makes it go high again. However, thinking about it again, if we do that and for any reason the voltage hangs between our two thresholds, the cpu will never wake up again, or depending on the software perhaps never go to sleep again also.
For the purposes of making sure the power signal is somewhat smooth and consistent we should have two things:
1) a capacitor across the input to smooth things out (perhaps one 10uF tant and one 0.1uF ceramic)
2) a resistor to drain the cap in short order that won't get too hot with continuous 15v applied and won't burn out with continuous 25V applied.
The cap without the resistor would be a terrible idea in case there was only one thing supplied from the relay that triggers this pin (quite likely). The resistor without the cap could result in random voltage swings.
This input pin will feed the BRV divider too, so having a bit of extra filtering on the outside (using the supply wire as a low resistance series resistance for a high cut off RC filter) is a good thing.
If we don't use something like a schmidtt trigger and just use a normal logic gate to invert the signal, then our switch point will depend upon the internal switch point of that device (fed with a zener and rail diodes to cap it) which could vary part to part.
I think I'd prefer the on/off threshold to be around 5v so that random leakage is less likely to appear "on". Whatever happens we don't want the situation where the thing goes to sleep and never wakes up because it went to sleep while the signal was high enough to force the cpu pin low and no transition occurs. Although, at that point it should only be a key on/off cycle away from waking it up, AND, it would only be caused by dodgy wiring anyway. Still, I don't like the idea of not having control of the destiny of the device so perhaps the schmidtt idea is a bad one.
Thoughts?
Fred.