What are some white compounds that look like powder (like flour) and immediately black after being heated? It turns immediately black and creates a odorous gas.
The answer to this question partially answers yours.
Let me speculate. The compound could be some crystallized organic compound, making it appear white. On heating, it degrades and becomes solid carbon, which is black, giving of some carbon dioxide and water vapour. It wouldn't have any sulfurous groups, as it would give off sulfur dioxide.