Packaging ints into bit arrays using serial communication

Hi all,

I'm trying to simulate a very simple communications protocol I'm unfamiliar with on the Arduino. The protocol normally takes in any data type and converts it into char values (regardless of message type), and then packs those char values via serial. I'm working with a specific kind of message that sends in 4 10-bit integers and package it into 1-byte "arrays" with elements of 1 bit. From a programming perspective, I want to use bitsets that are provided in C++'s standard library; however, I can't find a way to do this on an Arduino Uno processor. Is there a way to do this on Arduinos, and which libraries do I need to use to do this?

Thanks.

however, I can't find a way to do this on an Arduino Uno processor

What is stopping you ? What have you tried ?

Yeah, reading through my initial post wasn't detailed enough. I first tried using bitsets as defined by Arduinos but while they can access individual bits they don't quite do what I want. The most promising thing I looked at was the BitBool library which is nice but the goal is to transfer this communication protocol onto a different microcontroller so I would like to avoid using any extended libraries (though I'll try it if I can't find anything else). If people have any suggestions that would be highly appreciated.

while they can access individual bits they don't quite do what I want.

What do you want to do that bitSet() and its associated functions can't do ? How about accessing the bits in by using the bitwise operators ?