Autonomous CarLogBook with Oracle Apex on OCI (Part 4)

Autonomous CarLogBook with Oracle Apex on OCI (Part 4)

Conclusion

·

3 min read

How long did all of this take?

To be honest, it took longer than I had hoped. The reason for this was that I was the one requesting more and more features to be added. You know how clients can be. ;-)

In essence, the whole thing would have probably been completed within a week of work if I had just stuck with the quick and dirty code and settled for a few bugs.

What I Learned:

  1. Nginx:
  • Configuration Topics
  1. Node.js:
  1. Oracle Apex:
  • Dynamic Actions for automatic page refresh

  • Dynamic Actions for the Map Region (thanks to the Demo App)

  • FOS Notification Plugin fos.world

  • Current Time Plugin apex.world

  • Mobile vs. Desktop CSS - I didn't want to create two separate pages -

  • Setting Styles for Items/Buttons - Impressive Capabilities

  1. Oracle Pattern Matching:
  1. Oracle Spatial sdo_geom
  1. Forecasts

** Problems **

Connectivity: In some garages, the car may not be accessible, leading to potentially inaccurate location information. Occasionally, the vehicle may report being in Frankfurt (at Hyundai's German headquarters), which significantly hinders accuracy. However, since I can park my car in my garage in a way that allows it to receive radio signals, this issue is manageable.

image.png

Querying the KIA Service: Allegedly, there is a limit of 200 queries per day. Therefore, from the beginning, I've set the query time window from 7 am to 10 pm, instead of 0-24 hours. Initially, I used Crontab, but later switched to the Oracle Scheduler so that I can control it through the APEX frontend when needed.

Data Interpretation: One of the queries provides me with the WH and DISTANCE I've driven in a single day. However, if I drive less than 5km, it always shows 5km. For example, driving out of the garage to the post office and back: 5km. Otherwise, the DISTANCE is quite accurate. It also displays the WH per trip. From this, I can calculate KWH per trip and KWH/100km. However, the car's Drive History shows different values. Sometimes more, sometimes less, but generally more than 10% higher. UPDATE: I now understand that the calculation is based on the last 100km driven, regardless of the current distance traveled. Therefore, there's no calculation error on my part or KIA's, just a different basis for calculation that evens out over time anyway.

image.png

image.png

vs.

image.png

UPDATE Apex in my Car:

Autonomous CarLogBook with Oracle Apex on OCI (Part 5) (hashnode.dev)

Back to the beginning of this blog series:

yaitcon.hashnode.dev/carlogbook-with-oracle..

Find the Node.js code, DB Code, and Apex App for this project at github.com/yaitcon/carlogbook