-
-
Notifications
You must be signed in to change notification settings - Fork 92
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How nodes reset should be accomplished when flashing (new PCB too)? #262
Comments
More like "enhancing question" :) |
I don’t know if I will have ability to perform much tests after a week or so for sometime. If you have any ideas/insights, even small - will be glad :) Nice day! |
The "pairing" strategy could make this easier to manage because it would be built into a PCB with no user intervention. However, such a strategy would not be effective should a timer be built with an even number of nodes. The "chain" strategy allows any number of nodes to be used, but makes the system more complicated to wire up. Either way, if a node goes down, you lose the ability to self-update two of them (the broken one and the one it signals). |
Agree. Idk if you get that above I was comparing i2c resetting and gpio based resetting. Not i2c and “chain”. “Chain” has no benefits over i2c - I agree. |
I think setting up resets via node commands makes a lot of sense, and pairing makes a lot of sense to me as well. Even with an odd number, you could still fall back to manual updating as the project has always been. I don't really like how much of the GPIO your current working implementation requires. New node command code should be pretty minimal. Interested in thoughts from @ethomas997 and @pulquero on this. |
Agree. Actually we can implement „backup” option which would be beneficial
with odd number of nodes too. 1 node can be reset via gpio. Actually that’s
all. Right?
W dniu pon., 9.03.2020 o 14:01 Hazard Creative <notifications@github.com>
napisał(a):
… I think setting up resets via node commands makes a lot of sense, and
pairing makes a lot of sense to me as well. Even with an odd number, you
could still fall back to manual updating as the project has always been. I
don't really like how much of the GPIO your current working implementation
requires. New node command code should be pretty minimal.
Interested in thoughts from @ethomas997 <https://github.com/ethomas997>
and @pulquero <https://github.com/pulquero> on this.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#262?email_source=notifications&email_token=AFUHCAFYKOC6447GRDWRG43RGTZCJA5CNFSM4LCVL622YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEOHAN2I#issuecomment-596510441>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFUHCAEIEKB4LW47DUNOZS3RGTZCJANCNFSM4LCVL62Q>
.
|
That's a really good idea, actually. I like it. |
Meantime I will write what should be figured out:
Anything else? |
I have found only one downside of this “new” way of resetting. Nodes should be flashed just once via PC before inserting in the timer. Nothing life changing - just to be aware of. |
They could be done one at a time through the single GPIO reset (or at least one per pair). I expect the board would have jumpers for each nano to be temporarily connected to the GPIO reset. The user would move the jumper across one at a time during initial setup, and then leave it on the odd-numbered node if appropriate afterward. Let's avoid D12, otherwise we would need to set up an alternate when ARDUVIDRX wiring is used. (Rare but occasionally useful for some developers). Could D8 be used? Boards using this system should not be designed to the legacy hardware address selection spec, but I'm not sure if this would mess with the initial detection of pin grounding. If not, perhaps A1. At this point I'm pretty comfortable with this and ready to move it forward as a spec to be integrated into PCB and nano code. Give me a bit of Arduino code that accomplishes the task and I'll make sure it gets into the current nano code in the right place. The command sent to the node could be 0x73. Obviously a different method is used for the GPIO reset, but the existing work here can be used as a guide. |
I will carefuly read through your message later - about another points - but for now:
Consider using D12 anyway cause if it is in icsp header, user could absolutely easily connect D12 to the reset of another nano - it is provided in icsp too. So if someone would like to use this functionality without dedicated PCB or on old Delta5 PCB - jumper wires and soldering ICSP should be enough - besides connecting uart pins below the board.
Also without the special PCB, resetting via GPIO should be accomplished easily - just move the wire from gpio from one icsp header to another. What do you think? It is kind of worthy for me.
… Wiadomość napisana przez Hazard Creative ***@***.***> w dniu 10.03.2020, o godz. 03:23:
They could be done one at a time through the single GPIO reset (or at least one per pair). I expect the board would have jumpers for each nano to be temporarily connected to the GPIO reset. The user would move the jumper across one at a time during initial setup, and then leave it on the odd-numbered node if appropriate afterward.
Let's avoid D12, otherwise we would need to set up an alternate when ARDUVIDRX wiring is used. (Rare but occasionally useful for some developers). Could D8 be used? Boards using this system should not be designed to the legacy hardware address selection spec, but I'm not sure if this would mess with the initial detection of pin grounding. If not, perhaps A1.
At this point I'm pretty comfortable with this and ready to move it forward as a spec to be integrated into PCB and nano code.
Give me a bit of Arduino code that accomplishes the task and I'll make sure it gets into the current nano code in the right place. The command sent to the node could be 0x73. Obviously a different method is used for the GPIO reset, but the existing work here can be used as a guide.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Why board with this system could not utilize legacy numbering system? No idea why that’s might be the case. |
And yet another thought - I am not editing previous messages so you can reply via email: if Arduino got the resetting message ( If arduino got resetting message dedicated for it ( So effectively 2 messages would be sent - general reset and specific reset. |
I was writing from mobile - sorry for edits |
Because no boards should be designed to the legacy spec in the first place. |
Ok. So it is not related to this from hardware point. I get it though. Is there any new recommended way to make auto selection? Any definitive conclusions? |
Refer to #252 for the auto-numbering discussion, which seems to be narrowing in. I haven't had the time to fully understand the implications of using D12. |
Sounds reasonable. |
No objections from me |
Idea: connecting RXes VCC line (usually about 3V3) to the AREF pins of Arduinos + enabling AREF as external based. Advantages - readings "scaled" better and higher resolution of readings - if I get it right? Disadvantages - 4 more PCB traces What do you think? |
Unrelated to node reset spec. |
Specification is final and published here. https://github.com/RotorHazard/RotorHazard/wiki/Specification:-Node-hardware-reset |
Right, will open new issue |
#277 contains I2C write command with function stub only. Requires code to perform reset of other node and testing. |
So hello - especially to devs. I have a question according to nodes flashing "system" that I developed (big word, but what do you do). As you may know that approach was proven to be working on few platforms. In a nutshell: Raspberry sends "flashing data" via UART and Arduino that was recently reset is being programmed - because that's how bootloader works. Right now each node is being reset using Raspbery GPIO. So every Arduino has a reset pin connected to some of the GPIO pins of R-Pi. I even designed a new PCB with those changes in mind - and it can be achieved with proper cabling etc. So it just works. But I was thinking recently - are all those cables necessary? And I came up with an idea, that I2C bus can be utilized for reset purposes. (I performed some prototyping and it looks promising). I will paste my discussion with Michael (few messages):
My idea:
Arduinos may be reset via "themselves" by a command from a I2C bus. How?
If some command on I2C shows (may be anything, depends of the code on the Arduino as you know) it would perform digitalWrite D2 (or any other pin) LOW - and that would be connected to the reset pin of the NEXT Arduino. Why next and not to it's own reset pin? Redundancy. After some poweroloss or any error during programming, the "resetting" Arduino would still have ability to reset the "next" Arduino and Raspberry could program it again. That way only first Arduino would require connection between reset pin and Raspberry. So resetting would be "software based" but still safe.
Michael idea (good tbh) - Arduinos should be "paired", so Arduino 1 should perform a reset on Arduino 2 etc, 2 on 1, 3 on 4 and 4 on 3. Etc.
I agree.
Conclusion:
GPIO resetting:
Pros:
Cons:
I2C:
Pros:
Cons:
So, devs, what do you thinks?
Cheers
The text was updated successfully, but these errors were encountered: