Thanks Cobra!
I did see that post yesterday but main concern was about the fact the cobrapin could use the SPI instead of a GPIO.
I'll try to use this code this weekend if I have a bit of time.
Also, it looks like it's not real SPI to me on the Stern side.
I'll need to "reverse engineer" the pcb to get exactly what they did.
Have a great day.
Romain
--
You received this message because you are subscribed to a topic in the Google Groups "MPF Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/mpf-users/FuvYokPp_Qw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to mpf-users+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/eacd9918-9d26-4713-9b7e-6bb77a9158f6n%40googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/3a27aa3c-c47d-4e21-876a-403d5399bdb4n%40googlegroups.com.
Thanks for all the information!
Didn't know they provided some of their schematics. I feel dumb for having probed all the traces with my multimeter x)..
I hope testing the MPF code using SPI on Sunday.
Let me know if you did before me.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/9c7e49ef-1d84-4d71-85dd-d83d1dc25fcen%40googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/04b5af21-72d7-4898-b058-7c1474f5859bn%40googlegroups.com.
That might be the reason why!
Either I invert the signal in hardware or I remove the MOS and shot the gate to the drain.
Any counter-argument not to do that?
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/0f26e8a8-7383-4354-99d2-8ee43aea84een%40googlegroups.com.
Oh yeah! Indeed, way smarter to use the through all footprint to get the gate. Totally forgot about it.
I'm going to try it tomorrow.
I'll let you know.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/180430d6-2a7f-4289-b948-2902ac6e1404n%40googlegroups.com.
I used 5.1k.
I'm on a windows 10 with a ryzen 7 on it.
I left 50ms as a default so far.
Okay!
For the switches I meant what number you used for them ?
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/14cd5a3f-9268-40e5-8dec-f4251085d96bn%40googlegroups.com.
Okay.
It's not that they're not stable, it's more like s_trough1 (number: 6) doesn't turn on even though I actually have a ball in that position.
Then if I put another ball into trough, I have both s_trough1 and s_trough2 ON.
Also, I cannt get state ON of a switch if the previous is not ON. I'd assume it's due to MPF that doesn't allow a ball to be in a position N when there is no ball in N-1...
Do you have this behaviour too?
Apart from these behaviours, the switches states are really stable (not glitchy I mean).
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/1c62a423-8046-4639-bf28-abc96867661an%40googlegroups.com.
Shit, my hypothesis was so cool to me x)..
All of them are NO (as default).
They are optos (NC) but are inverted on the trough PCB so NO in the end.
What do you mean by parallel wiring?
Because the only things I have wired are the miso, the CS and the clock. The Stern trough is default apart from the pull up I added on both CS and Clock.
MPF makes no determination on an “order” of trough switches, it merely counts the number of active switches and tallies the ball count from that. It sounds like there may be some parallel wiring? Or are some switches wired NO and others NC?
--
You received this message because you are subscribed to a topic in the Google Groups "MPF Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/mpf-users/FuvYokPp_Qw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to mpf-users+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/CA%2B30LW6SG8mzBaeyOLhsrckwqW%2Bu_dkORbsJ%3DdiHuYuS3YF%2B9w%40mail.gmail.com.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/f291c09d-a88d-444e-b13f-d899e7171e36n%40googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/b08ecc06-0fd6-4368-82ce-8c46c131b2d0n%40googlegroups.com.
What do you mean?
I had to invert SCK so I used to jumper to connect the drain mos to the connector and I didn't have to invert RCK so I just wire jumped it directly to the connector.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/c3d37256-73ff-4c65-ab2e-ec116f661a79n%40googlegroups.com.
Oh yeah you're right, I'm so dumb x).
For some reason I rushed it and I was like 1-0-1 is the bluepill output when it's actually behind the MOS relay but not on the other side...
Meaning I actually inverted both signal and it works when it wasn't the case previously with the coil outputs.
Don't really get that right now. I'll remove that wire to solder the jumper and scope all of that tomorrow.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/be685b84-646a-4150-ae6f-65dd449c4117n%40googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mpf-users/5104cadd-edfb-4579-a42f-d738724e81f6n%40googlegroups.com.