Closed zerog2k closed 6 years ago
@ivankravets do you have any tip on how upload section would/could/should be implemented by platform-mcs51?
http://docs.platformio.org/en/latest/platforms/creating_board.html#json-structure says:
upload settings which depend on the platform
but doesn't seem immediately obvious to me how it would be used.
I was thinking maybe this is for some limits on code/ram size?, but in our case (sdcc), this already happens during build w/ options we have like (size_iram, size_xram, size_code, etc):
{
"build": {
"extra_flags": [
""
],
"f_cpu": "11059200",
"size_iram": 256,
"size_xram": 256,
"size_code": 4096,
"size_heap": 128,
"mcu": "mcs51",
"cpu": "8051",
"variant": "stc15w404as"
},
"frameworks": [
],
"upload": {},
"name": "stc15w404as",
"url": "https://github.com/platformio/platform-mcs51/wiki",
"vendor": "STC"
}
How does uploading work without PlatformIO? Could provide Makefile?
https://github.com/zerog2k/stc_diyclock/blob/master/Makefile#L32-L33 Generally, for stc mcus, stcgal (or oem STC-ISP app) detects target mcu and flashes accordingly. The ram/code size params are really only useful here during compilation, afaik.
Is there some doc which shows the boards/platforms/etc schemas, or otherwise explains what values are optional vs required, etc?
Yes, these options are requried
See refactored manifests https://github.com/platformio/platform-intel_mcs51/commit/a3928757cd835134d76ca34f701c00123208be6e
looks related to https://github.com/platformio/platformio-core/issues/1458
seems like in our boards jsons, we'll need to specify
upload.maximum_ram_size
andupload.maximum_size
, although not sure exactly what we would be using them for (not sure platform-mcs51 implements this).