47 pulsecounter_ptrs[pci] =
50 pulsecounter_ptrs[pci] =
56 pynq_error(
"Bitfile to old to use with pulsecounter.");
65 pulsecounter_ptrs[pci] = NULL;
69 uint32_t *timestamp) {
74 if (timestamp != NULL) {
109 uint8_t
const count) {
113 if (count < 1 || count > 15) {
114 pynq_error(
"Filter length needs to be between 1 and 16-1.");
121 const uint32_t inv_length) {
126 for (uint32_t l = 0; l < inv_length; l++) {
void arm_shared_close(arm_shared *handle)
void * arm_shared_init(arm_shared *handle, const uint32_t address, const uint32_t length)
void pulsecounter_reset_count(const pulsecounter_index_t pci)
pulsecounter_index_t
Enum of PULSECOUNTERs. Functions use a switch numbered from 0..NUM_PULSECOUNTERS-1.
void pulsecounter_set_edge(const pulsecounter_index_t pci, const int edge)
uint32_t pulsecounter_get_pulsetrain_count(const pulsecounter_index_t pci)
uint32_t pulsecounter_get_pulsetrain(const pulsecounter_index_t pci, uint32_t *const inv, const uint32_t inv_length)
void pulsecounter_set_filter_length(const pulsecounter_index_t pci, uint8_t const count)
void pulsecounter_destroy(const pulsecounter_index_t pci)
Close the shared memory handle for the specified PULSECOUNTER index.
uint32_t pulsecounter_get_count(const pulsecounter_index_t pci, uint32_t *timestamp)
void pulsecounter_init(const pulsecounter_index_t pci)
initialize the pulsecounter specified by the index with a shared memory pointer
uint8_t pulsecounter_get_filter_length(const pulsecounter_index_t pci)
int pulsecounter_get_edge(const pulsecounter_index_t pci)
version_t read_version(void)
const uint32_t PULSECOUNTER_PULSES
const uint32_t PULSECOUNTER_COUNTER
const uint32_t PULSECOUNTER_INTERVALS_COUNT
const uint32_t PULSECOUNTER_INTERVALS
const uint32_t PULSECOUNTER_EDGE
const uint32_t PULSECOUNTER_FILTER