gotthard works, data to be authenticated when personnel available

This commit is contained in:
2018-11-09 15:25:26 +01:00
parent 89fa30ee4b
commit 8942098a90
12 changed files with 276 additions and 101 deletions

View File

@ -114,6 +114,25 @@ u_int32_t writeRegister(u_int32_t offset, u_int32_t data) {
return readRegister(offset);
}
/**
* Read from a 16 bit register (literal register value provided by client)
* @param offset address offset
* @retuns 16 bit data read
*/
u_int32_t readRegister16(u_int32_t offset) {
return (u_int32_t)bus_r16(offset << MEM_MAP_SHIFT);
}
/**
* Write into a 16 bit register (literal register value provided by client)
* @param offset address offset
* @param data 16 bit data
*/
u_int32_t writeRegister16(u_int32_t offset, u_int32_t data) {
bus_w16(offset << MEM_MAP_SHIFT, (u_int16_t)data);
return readRegister16(offset);
}
/**
* Map FPGA