HAL library functions are too slow for tasks involving precise timing, and the MCU in the linked post is twice as fast as yours, so it'd be even worse. For a bit-banging 1-wire implementation only 3 register accesses are needed:
GPIOx->IDR to read the port,
GPIOx->BSRR to output a bit, and
SysTick->VAL, see below.
If you can't get
DWT->CYCCNT to work, there is the
SysTick->VAL counter, counting system clock cycles from the value in
SysTick->LOAD downwards to
0, that can used to measure short intervals, just keep in mind that it gets reset once every millisecond (assuming you didn't mess with the HAL SysTick configuration).
If you have a free UART TX pin, you can try implementing the procedure in Maxim Tutorial 214 Using a UART to Implement a 1-Wire Bus Master. I've found that it works best with the reset pulse sent at 7407 baud, and the data at 133333 baud. See also application note 27 for the CRC algorithm if you don't have this already.