Welcome to MattzoBricks Forums Sensors Using 8 sensors with MLC mini

Viewing 7 reply threads
  • Author
    Posts
    • #8025
      Des MatejkaDes Matejka
      Participant

      I am pleased to report my success with implementing the MLC mini with Sensors.
      The MLC-mini allows for 2 sensors.
      Clearly a layout will need more so I configured the MLC mini to take the maximum of 8.
      The coding seemed to work but I have discovered that Rocrail report the following:

      Sensor 5 on .pin = D0

      17:17:50 9999 simulate fb[MLC-36271-5] (null):36271:5 state=true
      It does not switch to state=false

      So once switched it stayed in that mode.

      All other 7 sensors work well.

      Any ideas would be greatly appreciated.

    • #8026
      Matthias RunteMatthias Runte
      Keymaster

      Hi Des,
      happy new year. Please refer to the documentation to find out why this is happening.

      MattzoLayoutController with Sensors

      Have a great year!

      Cheers,
      Mattze

    • #8032
      Des MatejkaDes Matejka
      Participant

      Thanks for your excellent help.
      It does pay to closely read the information.
      I had looked at the page earler but was put off by the illustration that didn’t quite match the board I was using for the MLC mini I had built.
      With some trial and error I finally understood the wiring and it now works as expected.
      I will need to incorporate the 100 kOhm resistor into the box, but that should be within my skillset.
      Any ideas would be greatly appreciated.
      Thanks again.

    • #8033
      Des MatejkaDes Matejka
      Participant

      I’ve just had another examination of the information and I had tested the Wiring Diagram MLC with 9 sensors. This required a 100 kOhm resistor.
      It did work perfectly.
      As I had planned on using 8 sensors, the Wiring Diagram MLC with 8 sensors and status LED seems to be what I need.
      In this case, I assume I alter my coding to assign the sensors to pins D1 to D8 and also assign status LED to D0.
      Is this a better option and more correct approach?

    • #8034
      Matthias RunteMatthias Runte
      Keymaster

      Yes, that is correct. Another approach would be to create some more MLC minis, which would relieve you from modifying the hardware or the wiring of particular units. These modifications are often only relevant for specific setups, and therefore only useful for layouts that remains like they are for a longer period of time. Users who change their layout often will be better off with standardized MLC minis.

      But that’s just my opinion. You’ve got all tools at hand, so decide yourself.

    • #8035
      Des MatejkaDes Matejka
      Participant

      My layout is more fixed, so customising the MLC mini is the way to go for now. As I am beginning with Rocrail I think I need to master how sensors are used.
      I feel confident now to build the MLC mini with 8 sensors. Looking forward to my next challenge with Mattzobricks Train Automation System.

    • #8036
      Matthias RunteMatthias Runte
      Keymaster

      Sounds good. When you layout is finished, you’re invited to help us publish it in the projects section of the website.

    • #8042
      Des MatejkaDes Matejka
      Participant

      Thank you, this would be my pleasure.

Viewing 7 reply threads
  • You must be logged in to reply to this topic.