I really love the design of the board! It has everything to build your robot. Your library is also contains a lot of work to make starters ready to go.
I am a bit more experienced user and I would like to implement micro_ros on your board for my robotics home lab. But your library has some conflicting pre compiled resources with micro_ros. I understand you want to keep your source closed (there is a lot of effort in it, and I loved playing with!), but is it possible to share some more information about which IC’s you used on what pins etc? E.g. like you did on with the MEMS sensor. So we can implement our own control? I already found the pins_arduino.h file but it does not provide information about which IC’s are used and what is on I2s or SPI.
This information would be a real advantage for me!
Hope you an share something for the little more advanced users who love your hardware as well
Correct. The precompiled library contains whole “background” implementation. This design is used because historical reasons. Initially X4 was supported trough Arduino library, so we needed to pack a bunch of code. Later we moved to our fork of ESP32 core to gain more control of Arduino environment. Plans for future releases is to split board control functionality from other services. So it’s constantly evolving.
The thing with X4 - it’s a bit more complicated than typical Arduino boards, so just having a schematic won’t do much. There are many differences between 1.0 and 1.1 versions that has to be accounted in software support. And more changes will come in future revisions.
The way it works - X4 contains STM32 (driver) that is in charge of dc, servo, rgb control. ESP32 communicates trough UART to send control commands. So it’s not as straightforward as simple pin mapping and some low level wrapper is required. This list of control commands is not documented and may change with firmware updates.
Our solution is to implement X4 board support package - a low level C API to control all the features. You will be able to include it as a component and use in any ESP-IDF based framework. For reference: https://github.com/espressif/esp-bsp
We just started to work on upcoming X4 software update and this bsp package may be available in January. Is this a sufficient solution for you? Always like to hear more ideas to unlock full potential of X4!
Thanks for your advanced and prompt reply. I already thought that the IC on the back is a STM32 but the numbering barely unreadable. I hope I can work out a ESP library, it seems micro_ros supports it as well. But that would totally differ from everything I have running here…
Never mind thanks for thinking with me.
micro-ROS uses ESP-IDF package (like any other framework) to add support for ESP32. ESP-IDF supports “components” (similar like Arduino libraries) to easy include software packages. They are placed in extra_packages directory and includes are available in application. This way you should be able to create a subscription and simply map to X4 motor control.
So unless you been using other MCU, this should be similar to any other ESP32 application. You would still need to use ESP-IDF libraries (like LEDC) to control motors over pin. Only difference - this step will be covered by X4 BSP library.
Haven’t tried myself, but seems it’s the way it works.