v2n-ros2-som-temperature
The smallest useful Alp SDK + ROS 2 node. It calls the portable temperature API in <alp/temperature.h> and republishes the values as sensor_msgs/Temperature: the SoC die temperature on /alp/soc_temperature and the on-module sensor on /alp/som_temperature. Runs on the Cortex-A55 under Yocto with ROS 2 Humble.
Source: examples/v2n/v2n-ros2-som-temperature/. New in alp-sdk v0.17.0.
[UNTESTED]It builds against a Yocto SDK that has ROS 2 Humble and the alp-sdk runtime. It is not built in CI and has not run on silicon; its HIL spec is not bench-verified.
alp_temperature_read_die_milli_c() --> /alp/soc_temperature
alp_temperature_read_milli_c() --> /alp/som_temperature
(portable Alp SDK API) sensor_msgs/Temperature [degC]
What it shows
- ROS 2 on the Cortex-A55 / Yocto side, with data from the portable API only — no chip driver, no vendor header, no SoM
#ifdef. The same source runs on any E1M SoM that carries Linux. - Graceful degradation by status code:
ALP_OKpublishes,ALP_ERR_NOSUPPORTlogs once and stays quiet, transient errors retry. - Parameters:
period_ms(default 1000) andframe_id(defaultsom).
Coverage today
alp_temperature_read_die_milli_c() has a Linux backend (the cpu-thermal* thermal zones), so /alp/soc_temperature carries data on V2N / V2M. alp_temperature_read_milli_c() — the on-module sensor — is implemented on the Zephyr AEN backend only; on V2N / V2M it returns ALP_ERR_NOSUPPORT, so the node logs one notice and /alp/som_temperature stays silent until a Linux backend lands. The node source will not change when it does. For a V2N node that reads real sensors today, see v2n-m1-ros-perception.
board.yaml
som:
sku: E1M-V2N101
preset: e1m-x-evk
cores:
a55_cluster:
app: ./src
recipe: alp-ros2-temperature # meta-alp-sdk/dynamic-layers/ros2-humble-layer/
diagnostics:
log_level: info
The ROS 2 stack is not a libraries: entry — it arrives with the image (IMAGE_FEATURES alp-ros, ALP_ENABLE_ROS2).
Build
Two ways, from the same CMakeLists.txt:
- Yocto image —
MACHINE=e1m-v2n101-a55 bitbake alp-image-edgewithmeta-ros2-humbleinbblayers.conf. The node recipealp-ros2-temperatureis not inpackagegroup-alp-rosyet; build it withbitbake alp-ros2-temperature. - colcon in the Yocto SDK (
bitbake alp-image-edge -c populate_sdk):
source /opt/<distro>/environment-setup-cortexa55-<distro>-linux
mkdir -p ~/ros_ws/src && cd ~/ros_ws/src
ln -s <alp-sdk>/examples/v2n/v2n-ros2-som-temperature alp_som_temperature
cd .. && colcon build --packages-select alp_som_temperature
Run
ros2 run alp_som_temperature som_temperature_node
ros2 topic echo /alp/soc_temperature
See also
v2n-soc-temperature— the same die-temperature read, without ROS 2microros-ros2-v2n— a micro-ROS node on the M33 publishing into ROS 2v2n-m1-ros-perception- Examples overview