Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. The Lounge
  3. Feeling kind of overwhelmed at the moment

Feeling kind of overwhelmed at the moment

Scheduled Pinned Locked Moved The Lounge
questionasp-netiotalgorithmsdiscussion
12 Posts 7 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • honey the codewitchH Offline
    honey the codewitchH Offline
    honey the codewitch
    wrote on last edited by
    #1

    I just got a neat little IoT widget but the screen appears to have been wired up to it at gunpoint. A critical control line (RST on the display) is connected not directly to the MCU, but to a control line (IO4) on the power management circuit for the device. Because of this, the display has to be in part indirectly operated by fiddling with the power system on the device. My existing display drivers simply don't account for such a situation, so I have to fork a driver just for this device. The source code provided for this device is not accurate to the device - meaning it doesn't work with it. I suspect there was an earlier edition of this device that was wired differently. I'm in one of those positions where I have to write a bunch of code only to hope it will work when I'm done with it. :~ And a question just occurred to me. I have a core driver that is general purpose but mostly works with this device. I could take a callback as one of the template parameters to mess with the RST pin but it adds complexity to the general purpose driver. The other option is forking the driver for this device. Anyone have any opinions on that?

    To err is human. Fortune favors the monsters.

    Mike HankeyM Greg UtasG Mircea NeacsuM Sander RosselS 4 Replies Last reply
    0
    • honey the codewitchH honey the codewitch

      I just got a neat little IoT widget but the screen appears to have been wired up to it at gunpoint. A critical control line (RST on the display) is connected not directly to the MCU, but to a control line (IO4) on the power management circuit for the device. Because of this, the display has to be in part indirectly operated by fiddling with the power system on the device. My existing display drivers simply don't account for such a situation, so I have to fork a driver just for this device. The source code provided for this device is not accurate to the device - meaning it doesn't work with it. I suspect there was an earlier edition of this device that was wired differently. I'm in one of those positions where I have to write a bunch of code only to hope it will work when I'm done with it. :~ And a question just occurred to me. I have a core driver that is general purpose but mostly works with this device. I could take a callback as one of the template parameters to mess with the RST pin but it adds complexity to the general purpose driver. The other option is forking the driver for this device. Anyone have any opinions on that?

      To err is human. Fortune favors the monsters.

      Mike HankeyM Offline
      Mike HankeyM Offline
      Mike Hankey
      wrote on last edited by
      #2

      And as soon as you finish they'll correct their mistake and it all will be for naught.

      The most expensive tool is a cheap tool. Gareth Branwyn JaxCoder.com

      raddevusR 1 Reply Last reply
      0
      • honey the codewitchH honey the codewitch

        I just got a neat little IoT widget but the screen appears to have been wired up to it at gunpoint. A critical control line (RST on the display) is connected not directly to the MCU, but to a control line (IO4) on the power management circuit for the device. Because of this, the display has to be in part indirectly operated by fiddling with the power system on the device. My existing display drivers simply don't account for such a situation, so I have to fork a driver just for this device. The source code provided for this device is not accurate to the device - meaning it doesn't work with it. I suspect there was an earlier edition of this device that was wired differently. I'm in one of those positions where I have to write a bunch of code only to hope it will work when I'm done with it. :~ And a question just occurred to me. I have a core driver that is general purpose but mostly works with this device. I could take a callback as one of the template parameters to mess with the RST pin but it adds complexity to the general purpose driver. The other option is forking the driver for this device. Anyone have any opinions on that?

        To err is human. Fortune favors the monsters.

        Greg UtasG Offline
        Greg UtasG Offline
        Greg Utas
        wrote on last edited by
        #3

        A display that has to be partially controlled by fiddling with the device's power system?! :laugh: Either you have a high tolerance for nonsense or you love a challenge. Probably both. :)

        Robust Services Core | Software Techniques for Lemmings | Articles
        The fox knows many things, but the hedgehog knows one big thing.

        <p><a href="https://github.com/GregUtas/robust-services-core/blob/master/README.md">Robust Services Core</a>
        <em>The fox knows many things, but the hedgehog knows one big thing.</em></p>

        honey the codewitchH 1 Reply Last reply
        0
        • Greg UtasG Greg Utas

          A display that has to be partially controlled by fiddling with the device's power system?! :laugh: Either you have a high tolerance for nonsense or you love a challenge. Probably both. :)

          Robust Services Core | Software Techniques for Lemmings | Articles
          The fox knows many things, but the hedgehog knows one big thing.

          honey the codewitchH Offline
          honey the codewitchH Offline
          honey the codewitch
          wrote on last edited by
          #4

          The power system apparently has 4 controllable GPIO on it. They've hooked the reset line up to it. I think I found a way to hack it without modifying my driver by simply toggling the LCD's reset GPIO on startup outside the LCD driver itself.

          To err is human. Fortune favors the monsters.

          J 1 Reply Last reply
          0
          • honey the codewitchH honey the codewitch

            I just got a neat little IoT widget but the screen appears to have been wired up to it at gunpoint. A critical control line (RST on the display) is connected not directly to the MCU, but to a control line (IO4) on the power management circuit for the device. Because of this, the display has to be in part indirectly operated by fiddling with the power system on the device. My existing display drivers simply don't account for such a situation, so I have to fork a driver just for this device. The source code provided for this device is not accurate to the device - meaning it doesn't work with it. I suspect there was an earlier edition of this device that was wired differently. I'm in one of those positions where I have to write a bunch of code only to hope it will work when I'm done with it. :~ And a question just occurred to me. I have a core driver that is general purpose but mostly works with this device. I could take a callback as one of the template parameters to mess with the RST pin but it adds complexity to the general purpose driver. The other option is forking the driver for this device. Anyone have any opinions on that?

            To err is human. Fortune favors the monsters.

            Mircea NeacsuM Offline
            Mircea NeacsuM Offline
            Mircea Neacsu
            wrote on last edited by
            #5

            In another life, I made a data acquisition program that had to work with hundreds of different devices that fell into just a few different categories. My choice was to make separate drivers for each device because they were dissimilar enough and trying to fit them into a one size fits all would add complications for users. Having separate drivers was a hassle for us because we had to manage and keep updated all those drivers, but I've always felt that it's better to inconvenience the programmer rather than the user (just because there are so many of them and they might come after you with their pitchforks). Surely, other people had the opposite idea and made some super drivers that would combine all the features in an incomprehensible mess. I haven't seem any of those drivers ever used. Now, mutatis mutandis, I would say you are at the beginning of a road where you face the same decision. You have no idea how clever those hardware engineers are to make the most annoying decisions from a software point of view. I'd bet that in a couple of weeks (or months) you will find another display that does something even more perplexing. To sum it up: fork!

            Mircea

            honey the codewitchH 1 Reply Last reply
            0
            • Mircea NeacsuM Mircea Neacsu

              In another life, I made a data acquisition program that had to work with hundreds of different devices that fell into just a few different categories. My choice was to make separate drivers for each device because they were dissimilar enough and trying to fit them into a one size fits all would add complications for users. Having separate drivers was a hassle for us because we had to manage and keep updated all those drivers, but I've always felt that it's better to inconvenience the programmer rather than the user (just because there are so many of them and they might come after you with their pitchforks). Surely, other people had the opposite idea and made some super drivers that would combine all the features in an incomprehensible mess. I haven't seem any of those drivers ever used. Now, mutatis mutandis, I would say you are at the beginning of a road where you face the same decision. You have no idea how clever those hardware engineers are to make the most annoying decisions from a software point of view. I'd bet that in a couple of weeks (or months) you will find another display that does something even more perplexing. To sum it up: fork!

              Mircea

              honey the codewitchH Offline
              honey the codewitchH Offline
              honey the codewitch
              wrote on last edited by
              #6

              Fortunately, I think I found a third option involving a minor, but acceptable hack wherein I tickle the reset line myself on boot and just tell the driver there is no reset line.

              To err is human. Fortune favors the monsters.

              1 Reply Last reply
              0
              • honey the codewitchH honey the codewitch

                The power system apparently has 4 controllable GPIO on it. They've hooked the reset line up to it. I think I found a way to hack it without modifying my driver by simply toggling the LCD's reset GPIO on startup outside the LCD driver itself.

                To err is human. Fortune favors the monsters.

                J Offline
                J Offline
                jmaida
                wrote on last edited by
                #7

                Seems the quality control for the display is lacking. Perhaps, you can sell your fixes before you share.

                "A little time, a little trouble, your better day" Badfinger

                honey the codewitchH 1 Reply Last reply
                0
                • J jmaida

                  Seems the quality control for the display is lacking. Perhaps, you can sell your fixes before you share.

                  "A little time, a little trouble, your better day" Badfinger

                  honey the codewitchH Offline
                  honey the codewitchH Offline
                  honey the codewitch
                  wrote on last edited by
                  #8

                  I think it was probably a design decision they made due to limited I/O available on the MCU. In IoT there are often compromises made, some severe - and I believe this is one of those cases.

                  To err is human. Fortune favors the monsters.

                  J 1 Reply Last reply
                  0
                  • honey the codewitchH honey the codewitch

                    I think it was probably a design decision they made due to limited I/O available on the MCU. In IoT there are often compromises made, some severe - and I believe this is one of those cases.

                    To err is human. Fortune favors the monsters.

                    J Offline
                    J Offline
                    jmaida
                    wrote on last edited by
                    #9

                    understood. you definitely know what you doing.

                    "A little time, a little trouble, your better day" Badfinger

                    1 Reply Last reply
                    0
                    • Mike HankeyM Mike Hankey

                      And as soon as you finish they'll correct their mistake and it all will be for naught.

                      The most expensive tool is a cheap tool. Gareth Branwyn JaxCoder.com

                      raddevusR Offline
                      raddevusR Offline
                      raddevus
                      wrote on last edited by
                      #10

                      Mike Hanley said

                      And as soon as you finish they'll correct their mistake and it all will be for naught.

                      So true. . . But, if you don’t complete the work, they’ll never correct their mistake. ~Engineer’s Paradox :rolleyes:

                      Mike HankeyM 1 Reply Last reply
                      0
                      • raddevusR raddevus

                        Mike Hanley said

                        And as soon as you finish they'll correct their mistake and it all will be for naught.

                        So true. . . But, if you don’t complete the work, they’ll never correct their mistake. ~Engineer’s Paradox :rolleyes:

                        Mike HankeyM Offline
                        Mike HankeyM Offline
                        Mike Hankey
                        wrote on last edited by
                        #11

                        raddevus wrote:

                        But, if you don’t complete the work, they’ll never correct their mistake. ~Engineer’s Paradox

                        :thumbsup:

                        The most expensive tool is a cheap tool. Gareth Branwyn JaxCoder.com

                        1 Reply Last reply
                        0
                        • honey the codewitchH honey the codewitch

                          I just got a neat little IoT widget but the screen appears to have been wired up to it at gunpoint. A critical control line (RST on the display) is connected not directly to the MCU, but to a control line (IO4) on the power management circuit for the device. Because of this, the display has to be in part indirectly operated by fiddling with the power system on the device. My existing display drivers simply don't account for such a situation, so I have to fork a driver just for this device. The source code provided for this device is not accurate to the device - meaning it doesn't work with it. I suspect there was an earlier edition of this device that was wired differently. I'm in one of those positions where I have to write a bunch of code only to hope it will work when I'm done with it. :~ And a question just occurred to me. I have a core driver that is general purpose but mostly works with this device. I could take a callback as one of the template parameters to mess with the RST pin but it adds complexity to the general purpose driver. The other option is forking the driver for this device. Anyone have any opinions on that?

                          To err is human. Fortune favors the monsters.

                          Sander RosselS Offline
                          Sander RosselS Offline
                          Sander Rossel
                          wrote on last edited by
                          #12

                          honey the codewitch wrote:

                          The other option is forking the driver for this device. Anyone have any opinions on that?

                          That's forked up!

                          Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                          1 Reply Last reply
                          0
                          Reply
                          • Reply as topic
                          Log in to reply
                          • Oldest to Newest
                          • Newest to Oldest
                          • Most Votes


                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • World
                          • Users
                          • Groups