Repository navigation
|
What is the relationship between the Hardware interface layer (HIL) and Hardware Abstraction Layer (HAL)? From my reading it looks like the HIL are the traits the capsules use to call the implementations inside the HAL, and the HAL is the chip low level driver code accessing registers and doing other unsafe things. |
Replies: 1 comment 2 replies
|
Hardware Abstraction Layer (HAL) is a concept. It's the idea that you can abstract away exact hardware details and use abstract versions of the hardware instead. For example, we have an SD Card Capsule, which requires a SPI peripheral. But it can accept any SPI peripheral, not just a specific chip's implementation. In Tock, typically Capsules use abstractions like this, but we don't ever really point at anything and specifically call it "the HAL" in Tock. Hardware Interface Layers (HILs) are specific traits that we use to abstract away hardware. I guess you could say they're the HALs? Or maybe them plus some capsule stuff? HILs are used to decouple capsules from chip-specific implementations, and are also used to guide chip implementations on what functionality is expected for a given feature. All the HILs in Tock live in the kernel (although we've always talked about moving them to their own folder). A couple of them have documentation clarifying their designs: https://github.com/tock/tock/tree/master/doc/reference |
Hardware Abstraction Layer (HAL) is a concept. It's the idea that you can abstract away exact hardware details and use abstract versions of the hardware instead. For example, we have an SD Card Capsule, which requires a SPI peripheral. But it can accept any SPI peripheral, not just a specific chip's implementation. In Tock, typically Capsules use abstractions like this, but we don't ever really point at anything and specifically call it "the HAL" in Tock.
Hardware Interface Layers (HILs) are specific traits that we use to abstract away hardware. I guess you could say they're the HALs? Or maybe them plus some capsule stuff? HILs are used to decouple capsules from chip-specific implementati…