# How to use C++/C based control plane on Tofino？

**URL:** <https://forum.p4.org/t/how-to-use-c-c-based-control-plane-on-tofino/1267>\
**Category:** Uncategorized\
**Created:** [March 4, 2025, 1:29pm UTC](https://forum.p4.org/t/how-to-use-c-c-based-control-plane-on-tofino/1267 "2025-03-04T13:29:02Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![aoiland](https://avatars.discourse-cdn.com/v4/letter/a/a9adbd/32.png) [@aoiland](https://forum.p4.org/u/aoiland)\
**Post date:** [March 4, 2025, 1:29pm UTC](https://forum.p4.org/t/how-to-use-c-c-based-control-plane-on-tofino/1267/1 "2025-03-04T13:29:02Z")

</div>

Hi, I want to use C++/C based control plane, but I do not know how to compile it and run it with Tofino switch. Is there any tutorial helps me to learn and use it?

---

<div class="post-metadata">

**Author:** ![vgurevich](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.p4.org/vgurevich/32/23_2.png) [@vgurevich](https://forum.p4.org/u/vgurevich)\
**Post date:** [March 4, 2025, 6:10pm UTC](https://forum.p4.org/t/how-to-use-c-c-based-control-plane-on-tofino/1267/2 "2025-03-04T18:10:33Z")

</div>

Dear @aoiland ,

The answer depends somewhat on whether you want to use Intel’s P4 Studio SDE or open-p4studio. I’ve just seen an almost identical question on ICRP Forum and I replied there with respect to Intels’ P4 Studio SDE situation.

With respect to open-p4studio, it does contain examples in `$SDE/pkgsrc/bf-drivers/bf_switch/bfrt_examples`, but they are not built (in fact, for whatever reason the subdirectory was removed from `$SDE/pkgsrc/bf-drivers/bf_switch/CMakeLists.txt`

Happy hacking,  
Vladimir
