It’s sore that’s for sure. I had the Mrs give me a good massage and that has helped a lot. It hasn’t taken care of all of the pain but at least is is kind of bearable.
I had to switch gears and focus my attention on downloading all of the property tax data from my county for every single property in the county. 220000+ properties. I am doing this because of the wild increase in property taxes where I live. My taxes went from 3200 a year to 5000 a year. On average there has been a 40% increase for all properties. I use that term “all” very loosely because I have found that properties that are worth 2 million+ have very small increases, like 5% at most. A large percentage of those properties have actually gone down!!!.. There is some really crooked stuff going on there. The county just released the mill rates for the next tax bill that is due and boy OH boy are some people going to be really mad. We have a thing called TABOR where I live. That is a Taxpayers bill of rights. It caps the spending that the county is able to do to 5% more than the year before. If they collect too much money for the amount they spend they have to refund it. The reason why people are going to get really mad is because right now the county has not adjusted the mill rates to bring down the amount they are collecting. So they are going to be collecting 35% more than they are going to be able to use. They are going to sit on that money for a full year. When they refund the money what they do is take the total amount and divide it by the number of residents and everyone that lives in the county gets a check. The issue there is a large portion of the people that live in the county never paid property taxes because they do not own a home. They are taking my money and giving it to someone else without my express permission. Where I am from that is called theft. Once I have all of the property and tax data I am going to calculate the amount they are collecting and I will see if the number they have listed in the budget for the year for the amount of property tax collected. The numbers better be close. I already know they aren’t going to be but I want to have the data in hand.
Then I am going to go and find an attorney and sue the county for fraud.
Test Event.
“Test Results: get_current_target_obj is functioning properly. Sliding the slider works without any hanging issues, and the label accurately reflects percentage changes.”
def slider_event_cb(self, event):
ev = lv.event_t(event)
obj = ev.get_current_target_obj()
print(f"slider_event_cb: {obj} {obj.get_value()} {ev.get_code()}")
self.slider_label.set_text(f"{obj.get_value()}%")
def lv_example_slider_1(self):
style_bar = lv.style_t()
style_bar.init()
style_bar.set_bg_color(lv.color_hex(0x00FF00)) # Green color
style_bar.set_bg_grad_color(lv.color_hex(0x808080)) # Gray color
style_bar.set_radius(lv.RADIUS_CIRCLE)
style_bar.set_border_color(lv.color_hex(0xFFFFFF)) # White color
style_bar.set_bg_opa(lv.OPA._90)
self.slider = lv.slider(lv.screen_active())
self.slider.add_style(style_bar, 20)
self.slider.set_size(15, 240 - 50)
self.slider.align(lv.ALIGN.LEFT_MID, 10, 0)
self.slider.set_range(16, 28)
self.slider.add_event_cb(self.slider_event_cb, lv.EVENT.VALUE_CHANGED, None)
# Create a label below the slider
self.slider_label = lv.label(lv.screen_active())
self.slider_label.set_text("0%")
self.slider_label.align_to(self.slider, lv.ALIGN.OUT_LEFT_MID, 50, 0)
Hello everyone,
the topic of Drivers is so acute that I reread the entire discussion from the very beginning. So, I decide to share my thoughts.
In most cases, the qualifications of users in this topic are not very high and they are ready to use ready-made solutions or adjust to themselves with minimal effort
The same display may have differences depending on the version, for example, CYD ESP32-2432S024C uses SPI for DISPLAY and I2C for TOUCH while CYD ESP32-2432S028 uses SPI both there and there. And I suppose this is not a unique case.
You are doing very deep and necessary work on standardizing solutions, and I would suggest creating a separate topic that captures the dry balance of the decisions or agreements reached.
Is it possible to combine into one file like DRV_CFG all the drivers used in a particular project, which contains only imports links to the necessary driver files? The file with the driver of a specific display/reader device can be typed by describing a base class that contains all the necessary default inits, functions and a description of some essential requirements for such calls? Such a file may include sections - D_BUS T_BUS … FW … and maybe some more, which contain general parameters, global variables, etc.
I understand that the more universal the solution is, the more difficult its description and nuances are inaccessible to a beginner, but he can be prompted by the key points to pay attention to first. The formulation of typical base classes and important driver requirements can facilitate the work of developers and focus efforts on achieving implementation success new or updated drivers.
I have actually done this already. This is exactly how the drivers are currently done on my version of the MicroPython Binding. Display drivers are written in Python code and the bus (data connection) drivers are written in C code. For the display drivers there is a common class that is used that all other display drivers subclass so they inherit the functionality of the parent class. By writing the drivers in Python code it allows for the most flexibility when needing to alter the behavior of a driver for some reason. A great example is adjusting how the rotation of a display is handled. Depending on how the display has been assembled will alter the rotation. The same thing holds true with touch screens as well.
The way I wrote the drivers also places all of the initialization commands into stack memory instead of on the heap. The initialization is also handled using a separate module from the actual display driver and that module gets unloaded from memory once it has finished running. No need to consume memory for code that runs only a single time.
The bus drivers also share a common interface to keep the memory consumption down. There is a core set of functions that all bus drivers share which reduces both the code footprint and also memory use.
I put a great amount of thought into how things should be handled as to offer the greatest amount of flexibility with as low a resource use as possible. I also focused on making everything work at runtime instead of having to pick things at compile times. This allows a user to change out displays attached to an ESP32 without the need to compile and flash the firmware. Simply upload the new display drivers and run them. I also made sure the people could compile for macOS and also compile on macOS…
One other thing I just recently added was being able to compile the library using a TOML file. The user is able to specify the MCU being used and to enter all of the parameters needed to get a display up and running as fast as possible.