Skip to content
This repository has been archived by the owner on May 9, 2024. It is now read-only.
/ PicoOSC Public archive

OSC communication for the Raspberry Pi Pico using the C++ SDK

License

Notifications You must be signed in to change notification settings

madskjeldgaard/PicoOSC

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PicoOSC

A simple library for OSC communication using the lwip library that comes with the Raspberry Pi Pico C++ SDK.

This library was written for the Raspberry Pi Pico, but it should be able to work on other platforms that use lwip with a few modifications.

Support

This library is still a work in progress. Feel free to contribute to make it fully compatible with the whole osc specification !

It currently supports:

  • ✅ An OSC client interface:
    • ❌ multiple types in one message
    • OSC Message types:
      • ✅ string
      • ✅ float
      • ✅ int
      • ❌ blob
      • ❌ time tag
  • ❌ An OSC server interface
  • ❌ Bundles

Usage example

Sending an integer

// Setup UDP target
const auto target = "192.168.0.105";
const auto port = 3333;

picoosc::OSCClient client(target, port);

// Make an integer message
picoosc::OSCMessage msg;

msg.addAddress("/picoint");
msg.add<int32_t>(8); 

// Send the message
msg.send(client);

Adding this library to your project

Using CPM

The easiest way to use this in your project is to install it using CPM. Add the following lines to your CMakeLists.txt. This will automatically download and include it in your CMake setup.

# Add Debounce
CPMAddPackage("gh:madskjeldgaard/PicoOSC#main")
target_link_libraries(SimplePicoMidiController PicoOSC)

Manually

If you have a project called SimplePicoMidiController, you can link this library in your CMakeLists.txt like so (assuming you downloaded the library and placed it in the path noted below):

# Add Debounce
set(PICO_OSC_PATH "include/PicoOSC")
add_subdirectory(${PICO_OSC_PATH})
target_link_libraries(SimplePicoMidiController PicoOSC)

Releases

No releases published

Sponsor this project

Packages

No packages published