Saturday, December 30, 2017

My Connected Car: display car position on a Map

I'm currently working on the Python module that is in charge to read data from OBDII and send data to the MQTT broker.

In the meanwhile, I'm exploring how to add position (latitude, longitude from GPS) and display these positions on a Map.
Till now, I don't have a working GPS module on my RPI (I have two available, still in test phase).

But, since I have decided to use a SmartPhone to provide connectivity to Internet, one solution I have found (for now) is to use  OwnTracks.

In addition, I have added WorldMap to my NodeRED instance. And, with a simple flow, I'm able to show the current position of my Car on a Map.

Amazing...




In release 2 of my project, I'll integrate it with Oracle IoT Fleet Management. With this integration enabled I'll get many more features. An example is the view shown below, that shows cars' locations on a map.



Stay tuned.

Friday, December 29, 2017

My Connected Car: First tests on Car

Yes, it works !

Today, 29/12/2017 I have tested my Python code on my car (a BMW X1) and it has worked fine.

Therefore, I have marked the set of code as release "0.6": it is more than half of the way towards release "1.0".

I have also setup some NodeRED flows on my (Oracle) Cloud environment and in about 50 min. of tests about 300 msgs have been saved in a MySQL table.
Every record contains the JSON msg sent to th Cloud. For now only for storing purposes.

Have a look:



If you want to have a look at the code, here it is: OBDII github

My Connected Car project

If you want to follow my progress on the project here some information.

I have started the development of the code that will run on the RPI 3.

Here is the link to the github repository:


If you have any suggestion, comments or want to contribute to the code, let me know.

Thursday, December 28, 2017

Back to Iot: (My) Connected Car

I've been away for a while. Yes, I've not blogged for some time, because I've been busy working and training for my Half Marathon efforts.

Now, I have decided to start a new project: a Connected Car project. And I'll blog about it.

For now, I want only to highlight the idea.

Using:
  • A Raspberry PI 3
  • A SmartPhone
  • An OBDII bluetooth dongle
  • Cloud Services
I want to build a system that enables us to send realtime information from a Car to a Cloud Service where these data can be displayed on a Real Time Dashboard, analyzed and stored for later use.
Yes, I'm talking about a Real Car!

And more, I want to build a system that is:
  • Low cost
  • Open Source
Stay connected.

Friday, September 1, 2017

Running performance

An important part of running training is to measure the current level of fitness and define optimal speed for each different kind of exercise (long running, interval training, ...)
If you run below a threshold (depends on your strenght and current fitness level) the mechanics of energy production is principally aerobic. Above this threshold the anaerobic mechanism become more and more important.
Therefore it is important to measure the current value for the Anaerobic Threshold (AT, in Italian SAN).

In the past an Italian physiologist (F. Conconi, see, for example https://www.ncbi.nlm.nih.gov/pubmed/7085420) has proposed a "non-invasive" test to measure the threshold, that is called "The Conconi Test".
Belove the threshold the heart rate increase linearly with speed. After the threshold increasing the speed the heart rate increase with a lower rate and finally it reaches a maximum. 
In this test, you run at a progressively increasing speed (10, 10.5, 11... km/h) and you measure the corresponding heart rate.
In this way you can measure the threshold.

I have developed a small Jupiter Notebook (http://jupyter.org/), using Python, SKLEARN and Ordinary Least Square Method to analyze the data from one recent test, to assess my linear region and my anaerobic threshold.
I have also compared the data with another test, run on a treadmill and it confirmed that, at least for me, it is much easier to run on a treadmill.

The code is in one of my github repositories: