Announcement

Collapse
No announcement yet.

Question About genieArduino Display Driver Library

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Question About genieArduino Display Driver Library

    Hi,

    Looking at the code listings for genieArduino, I noticed in genieArduino.h (line # 177) that the declaration shows the return type for the WriteObject function is uint16_t. However, looking at genieArduino.cpp (lines # 635-669), I cannot find any return listed in the function definition. Where in the code is a value of type uint16_t generated and returned from this function?

    Also, I noticed that the object, index, and data arguments are all listed as type uint16_t. However, the range of values associated with the Object ID only spans the range from 0x00 - 0x21 and I cannot imagine the range of the Object Index exceeding 0xFF on the upper end. Why did 4D Systems choose to use uint16_t for these argument types when it appears that uint8_t would have been more than adequate?

    I am still a newbie when it comes to C/C++ coding but I am trying to learn as much as I can.

    Thanks in advance for responding to my neophyte questions.

    Charlie

  • #2
    Originally posted by roadwarrior1951 View Post
    Also, I noticed that the object, index, and data arguments are all listed as type uint16_t. However, the range of values associated with the Object ID only spans the range from 0x00 - 0x21 and I cannot imagine the range of the Object Index exceeding 0xFF on the upper end. Why did 4D Systems choose to use uint16_t for these argument types when it appears that uint8_t would have been more than adequate?
    Now in the year 2020 I am still puzzled why it is done that way, I expect that it is just a mistake among others in the library which is very sad because there are actually many programmers that rely on it. It has also been ported this way to the new C library. Unfortunately, the libraries are very complex and not easy to debug at all, even for experienced programmers.
    I really think that 4D Systems should be able to find experienced programmers to fully debug and polish the libraries if most of their displays are based on them.

    Comment

    Working...
    X