My implementation exceeds the maximum memory for BJS1 while running on BJS2 and the before render call in both implementations indicates a higher memory usage on BJS1 in general.
After figuring out the issue with the RAM I also dropped the huge fonts and rely on the available 6x8 font now. I also started nesting the calendar elements, so I don't have to have the extra function rendering over my layout, but can simply update the day of the month with layout['day-of-month'].label = date.getDate();
While it seems to be sufficient to specify col: FG_COLOR on the root element of the layout for BJS2, it requires BJS1 to explicitly specify it per type: "txt" element to make it work.
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
@g_lander thanks for your hint. It was indeed uploading straight to RAM, changed the IDE now to upload to flash.
Original implementation BJS1 uploaded to RAM
Original implementation BJS2 uploaded to RAM
My implementation BJS1 uploaded to RAM
My implementation BJS2 uploaded to RAM
My implementation exceeds the maximum memory for BJS1 while running on BJS2 and the before render call in both implementations indicates a higher memory usage on BJS1 in general.
After figuring out the issue with the RAM I also dropped the huge fonts and rely on the available 6x8 font now. I also started nesting the calendar elements, so I don't have to have the extra function rendering over my layout, but can simply update the day of the month with
layout['day-of-month'].label = date.getDate();
My updated implementation BJS1 uploaded to RAM
My updated implementation BJS2 uploaded to RAM
My updated implementation BJS1 uploaded to Flash
My updated implementation BJS2 uploaded to Flash
Difference between rendering on BJS1+2:
While it seems to be sufficient to specify
col: FG_COLOR
on the root element of the layout for BJS2, it requires BJS1 to explicitly specify it pertype: "txt"
element to make it work.