A repository containing the source code for various 8051 MCU tutorials I post as informative videos on YouTube (possibly other sites to follow).
A few helpful links & resources...
AT89S52 Datasheet:
https://ww1.microchip.com/downloads/en/DeviceDoc/doc1919.pdf
C51 Assembler:
https://www.microchip.com/en-us/development-tool/C51ASM
SDCC:
https://sdcc.sourceforge.net
Other Resources or References:
Intel Corporation, (1994), MCS 51 MICROCONTROLLER FAMILY USER'S MANUAL.