Makahiya – PCB & server

Hi everybody,

Since last Sunday, I worked on the PCB and on the server. First, on the PCB, I did a complete check of both the schematic and the routing, to find the remaining errors. Alexis also did it on his side, and we both found errors. After having corrected them, I gave my approval to send the PCB to the factory, and so did Tanguy. We should have received them in 8 working days. But as we don’t really need them during Christmas holidays, a longer delay is possible (which is good as it reduces the cost). So our PCBs have still not been sent. But we received 2 evaluation boards for the Wi-Fi module. Thanks to them, we’ll have the opportunity to develop the driver to control the Wi-Fi connection with ChibiOS. Alexis will also solder an evaluation board for the Bluetooth module, so that we can also work on it during the holidays.
After having finished my work on the PCB, I spent several hours on the server. I faced many problems with git subrepo, and thanks to Perceval help, I manage to get rid of it. So now, it’s much easier to work with Heroku. I’ve added authentication to our server and I tried to add links between the tables in our database. But I faced several problems, some due to the facts that I didn’t wrote all the code (Tanguy is also working on the server) and that I assumed things that happened to be different (for instance, we use a Postgre database on Heroku but a SQLite one for Continuous Integration because Tanguy has the impression that it’s not possible to install a Postgre database in the test environment).

As working on almost the same thing at the same time seems to be a rather bad solution, I will probably start to work on the Wi-Fi module and let Tanguy continue his work on the server. So by the end of the week, I will learn how ZentriOS works and start to write the driver that will control the Wi-Fi module.

BreathUp : first full version of deploy webApp with unit tests


The plan for the end of the week was to add a database and a way to authenticate the users and here is what I managed to do :

  • Add a PostGreSQL database to store the users credentials and authorizations and to store the devices status and configurations.
  • Try to add OAuth2 with Google as a provider : didn’t succeed because Google doesn’t want raw IP as callback uri.
  • Deploy on heroku: I spend like 3hours, 25 “WIP trying to deploy” commits, and 20 deployment versions (thanks Heroku for the count) before I found a great documentation explaining precisely what I was needing…
  • Add OAuth with another 20 WIP commits and deployments as I wasn’t able to test it on my computer. And I can confirm that Heroku is quite fast, but when you have to deploy 40 times in a day, it’s clearly not fast enough…
  • Make some correction to have something clean: and here we are with 53 deployments in 3 days 🙂
  • Add a lot of unit tests to obtain a decent coverage ratio. Sadly, 100% is impossible as I can’t test Google authentication… But If I remove this part, we are at 95% on the view file and 100% in the others. And I’m thinking about considering that this is fine…

Ok, but what are we still missing to say that the webApp is finished?

  • Some page rendering, because there are horrible.
  • Adding a new table to the database to store old reports from devices.
  • Implementing some thing to return at the next ping from a device it’s configuration if it has been modified.
  • Finding a way to receive, store and send  large files with the ADS and IMU datas.

And that will be my job for the next week, with maybe some more test on a LoRa module. It could be great if I managed to send back a message to it.

Have a nice week,

Xavier Chapron